Delete nodes from BST

My code is giving correct output but it is not passing all the test cases. Please Help!!

hello @avijuneja2007

u are not updating ur root node after deletion.

image

this line should be
root=deleteBST(root,x);

2 Likes