What’s wrong here in my code…
Why it is showing wrong answer…
Why showing wrong answer
hello @ashishnnnnn

put them outside ur if statement.
the condition that u have mentioned should be only on current node.
check ur updated code here->
Thanks… I got it where i was doing wrong…