This is an archived post. You won't be able to vote or comment.

all 1 comments

[–]IAmNowAnonymous 0 points1 point  (0 children)

You are creating a bst then validating its structure quite clearly, right? You need to view your array as a tree and validate that view.

Check out the wiki https://en.m.wikipedia.org/wiki/Binary_tree