Array
108. Convert Sorted Array to Binary Search Tree
Take the middle element of the sorted range as the root: everything to its left is smaller (the left subtree), everything to its right is larger (the right subtree) — that's the BST property for…
Loading…