package leetcode;

/**
 * https://leetcode.com/problems/insert-into-a-binary-search-tree/
 */
public class Problem701 {
    public static class TreeNode {
        int val;
        TreeNode left;
        TreeNode right;

        TreeNode(int x) {
            val = x;
        }
    }

    public TreeNode insertIntoBST(TreeNode root, int val) {
        // TODO
        return null;
    }

    public static void main(String[] args) {
        Problem701 prob = new Problem701();
    }
}

@@ -349,131 +349,264 @@
     
-// TODO%0A        return null
+if (root == null) %7B%0A            return new TreeNode(val)
 ;%0A    
+ 
-%7D%0A%0A    public static void main(String%5B%5D args) %7B%0A        Problem701 prob = new Problem701()
+   %7D%0A        if (root.val %3E val) %7B%0A            root.left = insertIntoBST(root.left, val);%0A        %7D else %7B%0A            root.right = insertIntoBST(root.right, val);%0A        %7D%0A        return root
 ;%0A  

Solve problem 701 (my 600th problem :)