Search⌘ K
AI Features

Two Sum IV - Input Is a BST

Two Sum IV - Input Is a BST asks whether a binary search tree contains two distinct elements whose values add up to a given target, returning true or false. Values may be negative.

Statement

Given the root of a binary search tree and an integer k, determine whether there are two ...