2. |
Figure 2
|
||
|
Figure 2 shows the 5 levels of tree data structure. List the nodes according to the terminologies.
|
||
|
(a) |
Sibling of E.
|
[1 MARK] |
|
Answer:
|
||
|
|
|
|
|
(b) |
Parent of L.
|
[1 MARK] |
|
Answer:
|
||
|
|
|
|
|
(c) |
Root of the tree data structure.
|
[1 MARK] |
|
Answer:
|
||
|
|
|
|
|
(d) |
Children of C.
|
[1 MARK] |
|
Answer:
|
||
|
|
|
|
|
(e) |
Leaf Nodes.
|
[6 MARKS] |
|
Answer:
|