Search
⌘K

Leetcode 98. Validate Binary Search Tree

Determine whether a binary tree is a valid binary search tree by checking that each node's value is strictly greater than all values in its left subtree and strictly less than all values in its right subtree. This requires a traversal that enforces global min/max bounds from ancestors (or equivalently verifies an inorder traversal yields a strictly increasing sequence).

Asked at:

Amazon

Amazon


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Late May, 2025

Amazon

Amazon

Junior

Check if a given tree is valid BST, implement edge cases and implement in another way

Comments

Your account is free and you can post anonymously if you choose.