Tree Height

https://codility.com/demo/take-sample-test/tree_height