Two Sum IV - Input is a BST

Easy · Binary Search Trees · about 10 minutes

Asked at Meta, Microsoft, Amazon, Google.

Decide whether a binary search tree contains two different nodes whose values add up to k.

Related guides