Trees Notes

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/26

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 8:28 PM on 5/7/24
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

27 Terms

1
New cards

Tree

A nonlinear data structure in Java organized hierarchically with nodes and edges connecting them.

2
New cards

Node

Elements stored in a tree, can be parents, children, leaves, or internal nodes.

3
New cards

Edge

Connects nodes in a tree structure.

4
New cards

Parent

Nodes above another node that connect to a node beneath them.

5
New cards

Child

A node below another node in a tree connected by an edge.

6
New cards

Root

A node with no parents, at the top of the tree.

7
New cards

Leaf

A node with no children, at the bottom of the tree.

8
New cards

Internal Node

A node with both parents and children.

9
New cards

Siblings

Nodes with the same parent in a tree.

10
New cards

Path

Route from a parent node to a leaf in a tree.

11
New cards

Height

Longest path from the root to a leaf in a tree.

12
New cards

Order

Number of children a node can have in a tree.

13
New cards

Balanced Tree

All leaves are within one level of each other.

14
New cards

Complete Tree

Balanced tree where all leaves on the bottom level are on the far-left side.

15
New cards

Preorder Traversal

Visit root, left node, then right node and their children in a tree.

16
New cards

Inorder Traversal

Visit far-left leaf, then parent, and right children in a tree.

17
New cards

Postorder Traversal

Visit children before the root in a tree.

18
New cards

Level-Order Traversal

Visit each level left to right in a tree.

19
New cards

Binary Tree ADT

Abstract Data Type with methods like getRoot, isEmpty, size, contains, and toString for a binary tree.

20
New cards

Ancestor

A node above another node on a path

21
New cards

Binary Tree

A tree where each parent has at most two children

22
New cards

Binary Search Tree

A tree in which the left child is always less than the parent and the right child is always more than the parent

23
New cards

Descendant

A node below another node on a path.

24
New cards

Full

A tree where all nodes have all the children they can have and all leaves are on the same level.

25
New cards

Freelist

A list of all available spaces on an array representation of a tree.

26
New cards

General tree

A tree with no limit on the number of children a parent can have

27
New cards

Level