Explain the error please

code: https://ide.codingblocks.com/s/228382

just add
return root;
at the end of BuildTree function

also add endl after calling inorder preorder postorder