Purpose: The purpose of this assignment is to give you exercise to
Become familiar with tree, binary tree
Become familiar with linked binary tree structure and array-based binary
tree structure
Exercise 1:
For the following tree, answer following questions:
a. Which node is the root?
b. What are the internal nodes?
c. How many descendents does node cs016/ have?
d. How many ancestors does node cs016/ have?
e. What are the siblings of node homeworks/?
f. Which nodes are in the subtree rooted at node projects/?
g. What is the depth of node papers/?
h. What is the height of the tree?
Exercise 2:
1. Draw a (single) binary tree T such that:
a. Each internal node of T stores a single character
b. A preorder traversal of T yields EXAMFUN
c. An in order traversal of T yields MAFXUEN
2. Assume the above binary tree is arranged in a Linked binary tree structure, draw a figure to represent the binary tree [hint: take a look at figure 7.14]
3. Discuss the pros and cons of the array-list representation of a binary tree.
Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.
You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.
Read moreEach paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.
Read moreThanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.
Read moreYour email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.
Read moreBy sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.
Read more