1class Solution {2 public TreeNode insertIntoBST(TreeNode root, int val) {3 if (root == null) return new TreeNode(val);45 if (root.val > val) root.left = insertIntoBST(root.left, val);6 else root.right = insertIntoBST(root.right, val);78 return root;9 }10}
WPM •0 •0
ACC •0 •0
TIME •0