Question: Write a recursive function called findSecondSmallest for the BinarySearchTree class that returns a pointer to the node containing the second smallest item. If there
Write a recursive function called findSecondSmallest for the BinarySearchTree class that returns a pointer to the node containing the second smallest item. If there is no such item, then return nullptr. The function prototype is shown below. BinaryNode * findSecondSmallest (BinaryNode* t) const;
Step by Step Solution
There are 3 Steps involved in it
include struct BinaryNode int data BinaryNode left BinaryNode right BinaryNodeint value datavalue le... View full answer
Get step-by-step solutions from verified subject matter experts
