Lab Tasks
Exam Style Questions
- Give the recursive definition of a tree.
- What is the asymptotic {space,time} complexity of the {DFS,BFS}
algorithm?
- Give the algorithm for a {DFS {preorder,postorder},BFS} traversal
of a tree.
- List the nodes visited in the order of a {DFS {preorder,postorder},BFS}
traversal of this tree.
[Picture of some tree, make up your own :-]
- Draw the generalized linked list representation of this tree.
[Picture of some tree, make up your own :-]
- Draw the left child - right sibling representation of this tree.
[Picture of some tree, make up your own :-]
- Draw the binary tree representation of this forest.
[Picture of some forest, make up your own :-]
- Give the algorithm for a {preorder,inorder,postorder} traversal of
a forest.
- List the nodes visited in the order of a preorder,inorder,postorder}
traversal of this forest.
[Picture of some forest, make up your own :-]