// Helene Martin, CSE 143 // Creates a tree of integer and prints its elements in different orders. public class IntTreeClient { public static void main(String[] args) { // build a tree out of nodes (use the jGRASP debugger to see its // structure) IntTreeNode root = new IntTreeNode(17); root.left = new IntTreeNode(41); root.left.left = new IntTreeNode(29); root.left.right = new IntTreeNode(6); root.right = new IntTreeNode(9); root.right.right = new IntTreeNode(40); root.right.left = new IntTreeNode(81); // set the tree's overall root as the root of the tree we just built IntTree tree = new IntTree(root); // use the jGRASP debugger to see the different traversal orders tree.printPreOrder(); tree.printInOrder(); tree.printPostOrder(); } }