Why this output wrong?
@codingblockscpp i dont see any equality signs in your buildTree function? its giving completely wrong output if there are repeating keys in the input
https://ide.codingblocks.com/s/238328 now what is the problem … i have made left side BST to hold equal value also
https://ide.codingblocks.com/s/238328 this is working on multiple test cases but why still giving wrong ans
@codingblockscpp you can see that the tree formation is incorrect https://ide.codingblocks.com/s/238328 for second test case
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.