Insert the given keys into the initially empty binary search tree.
The keys can be inserted by drag & dropping them from the Stream of Keys into the correct positions in the tree below. If there are equal keys they are always inserted into the left branch of the existing node.
Some additional problems.
Insert(Node root, Key k) 1 if (root == null) // insertion position found 2 return new Node(k); 3 if (k <= root.key) // proceed to the left branch 4 root.left = Insert(root.left, k); 5 else // k > root.key, i.e. proceed to the right branch 6 root.right = Insert(root.right, k);