Find if sum of two nodes is equal to a given number in BST

Problem Statement:Given a binary search tree T, where each node contains a positive integer, and an integer K, you have to find whether or not there exist two different nodes A and B such that A.value + B.value = K.Return 1 to denote that t