BST Operations (BSTOPS) : getting wrong answer

Can anybody help me find the error in my code as I am getting wrong answer for the problem BST Operations having code “BSTOPS” in the beginner section. My solution code is : CodeChef: Practical coding for everyone
I thought that in case where a node has two children it would be printing twice so I created a method “deleteNode” and copied the functionality of method “delete” without printing the position, still I am getting wrong answer. Solution code for this is CodeChef: Practical coding for everyone

1 Like