sir i did not understand use of line 110,111 in the code.
Binary tree level order
hey @ayush15goel, we just want that element of different level appears in different line. Thatswhy when we poped all elements of one level and queue still has element, we are pushing NULL so that next time elements of next level gets printed in new line (because of lines: node f = q.front();if(f==NULL){cout<<endl;q.pop();* )
Understood sir.Thank you
hey @ayush15goel, if your query is resolved. Please mark this doubt as resolved and rate me on the basis of your experience.
rating option will appear when to mark this doubt as resolved
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.