So my work on trees lab is given below. I tried to remove redundancy that could potentially arise when t.children is empty and I did not follow the instructions on the handout closely... I kind of have my own way of doing things, which was mostly based on intuition at first, but after today's lab, I think I kind of know what I am doing. Maybe for a future post, I will elaborate on my way of tackling recursive problems.
Additional exercises and one extra function from lecture is also included.
Thanks alot, this was very helpful.
ReplyDelete