Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- I am going to give you a struct output. Your job is to format this struct in a readable manner and draw a text-based tree at the end. Make sure that the tree's a big one — there should be enough space between the nodes to see clearly, the children of each node and the key/value of each node in the node itself. Make sure to identify any inconsistencies in the tree's structure, e.g Node 1 has its right child pointing to node 3, and node 3's parent points to node 2. Remember that trees are implicitly self-referential, so don't be concerned about infinite recursion
- For the struct output, make each node be a separate line of the output for readability
Advertisement
Add Comment
Please, Sign In to add comment