Driver Code
public static void Main ( string [ ] args ) { int [ ] pre = new int [ ] { 1 , 2 , 4 , 8 , 9 , 5 , 3 , 6 , 7 } ; int [ ] post = new int [ ] { 8 , 9 , 4 , 5 , 2 , 6 , 7 , 3 , 1 } ; int size = pre . Length ; node root = constructTree ( pre , post , size ) ; Console . WriteLine ( " Inorder ▁ traversal ▁ of ▁ " + " the ▁ constructed ▁ tree : " ) ; printInorder ( root ) ; } }