Question: 2 0 . Saddle Point: Input: A binary tree T in which each node x contains a field value ( [ x ]
Saddle Point:
Input: A binary tree T in which each node x contains a field value x which is a real number.
We say a node x in T is a saddle point if x has minimum value among all its ancestors including x but it has maximum value among all its descendants including x
Output: A saddle point of T if there is one, or null if there isn't.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
