Driver code
public static void Main ( String [ ] args ) { Node root = newNode ( 1 ) ; root . left = newNode ( 2 ) ; root . right = newNode ( 3 ) ; root . left . left = newNode ( 4 ) ; root . left . right = newNode ( 5 ) ; Console . Write ( " Sum ▁ of ▁ heights ▁ of ▁ all ▁ Nodes ▁ = ▁ { 0 } " , getTotalHeight ( root ) ) ; } }