Level Order Traversal of Binary Tree | Using recursion | Using Queue

preview_player
Показать описание
In this video, I have discussed Level order traversal of a Binary tree. Level order traversal is type of breadth first traversal. Here, we traverse the tree from top to bottom with each level going from left to right.

00:00 Introduction
00:05 Level order traversal
01:02 Level order traversal using recursion
08:29 Level order traversal using queue
12:24 C++ Implementation

-------------------------------------------------------------
I live in New Delhi and love explaining programming concepts. I have done M.Tech(BITS Pilani) + B.Tech(PEC, Chandigarh) in Computer Science and am currently working as a software engineer in a MNC.
If you like my content, please like, share my videos and subscribe to the channel.
-------------------------------------------------------------

For other tree tutorials, please refer to the below links:

For in-depth Graph theory and implementation details, please refer to the below playlist:

#DataStructure,#Trees,#FitCoder,#Algorithm,#competitiveprogramming,#binarytree
Рекомендации по теме
Комментарии
Автор

00:00 Introduction
00:05 Level order traversal
01:02 Level order traversal using recursion
08:29 Level order traversal using queue
12:24 C++ Implementation

FitCoder
Автор

Thank you very much for the tutorial video, this is one of the best visual explanation for level order traversal of a tree via recursive and queue methods.

surjagain
Автор

I like your style of teaching and explaining the concepts . Keep coming more videos on trees .it’s really helpful for me

himanshidhamija
Автор

Good work. You deserve more likes and views.

keertikagupta
Автор

It is the best Explanation. Thank you sir..

gausiyasayyad
Автор

Hi teacher, I have a question:

why does sometimes, in your Traversal videos (pre/in/post oreder) the while loop is
(!stact.empty()) and sometimes (curr != NULL or !stack.emty())
how do you choose which is right?
Thanks a lot teacher, you are the best!

coolnerd
Автор

Recursion is good for DFS
Queue is good for BFS

hhcdghjjgsdrt
Автор

Curr me address ayega but you have put first element of queue if this is that is the address of that node in tree. How can we find address of node in tree by dropping element in queue

sachinraj
Автор

Sir Can you make Full DSA playlist covering all topics starting from arrays

gausiyasayyad
Автор

please make videos on graph algorithms

sagarsrivastava
Автор

Please create the videos about the math for competitive programming, and the computational geometry. Thank you.

join shbcf.ru