Create a binary tree given its `preorder` and `inorder` traversals or `postorder` and `inorder` traversals.