Driver code
public static void Main ( String [ ] args ) { BinaryTree tree = new BinaryTree ( ) ; tree . root = new Node ( 10 ) ; tree . root . left = new Node ( 20 ) ; tree . root . right = new Node ( 30 ) ; tree . root . left . left = new Node ( 40 ) ; tree . root . left . left . left = new Node ( 70 ) ; tree . root . left . right = new Node ( 50 ) ; tree . root . right . left = new Node ( 60 ) ; tree . root . left . left . right = new Node ( 80 ) ; tree . preorderIterative ( ) ; } }