Why my code is not giving correct answer


please append the code

Hey @harryson First we have to do a level order traversal which you did after you have to make a function in which we will connect Nodes Of Same Level. After that we have to print nodes of same level.
Here’s the draft of the code, you can take it for reference

how to print nodes of same level that is how to implement print nodes of same level

You can do a level order traversal for that.

can you please write the code for it

Have replied to you on chat, see it there

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.

no please give the function i am not finding it