This week was an exciting week. On one side, reading week is approaching. On the other side, term tests are nearing as well.
During class, we learned about the application of recursion in the form of trees. We went through the use of trees in computer science. We learned about the jargon used whilst talking about trees. We were taught aspects such as nodes(each circle), roots, parents(the node that is connected to a node below it), leaf(node with no children), subtree(tree formed by any tree node together with its
descendants and the edges leading to them). We also learned about the height of a tree and various paths. We went through code for preorder traversal and inorder traversal. We also went through the code to initialise the class of a tree. Surprisingly, the week ended with an assignment being posted based on trees, just two days after we submitted Assignment 1. I read through it and look forward to solving it.
No comments:
Post a Comment