Тёмный

Invert Binary Tree (LeetCode 226) | Full solution with diagrams and animations | Study Algorithms 

Nikhil Lohia
Подписаться 49 тыс.
Просмотров 9 тыс.
50% 1

Опубликовано:

 

1 окт 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 21   
@fortunefunda4171
@fortunefunda4171 5 месяцев назад
Sir at 13:42 you added 2 and 7 to the Queue but shouldn't 7 and 2 be added to Queue because you did swapping before this . I really liked your explanation but having this little doubt. Please clear this minor doubt.
@garvitarora7777
@garvitarora7777 5 месяцев назад
yes you are right
@nikoo28
@nikoo28 5 месяцев назад
Yep…sorry for the confusion
@ashok2089
@ashok2089 2 месяца назад
Others: Let's explain recursive approach, done. Nikhil: also explains BFS approach! That's why you are a gem!
@kanaramjangid8563
@kanaramjangid8563 2 месяца назад
Every videos has 110% of good explanation.
@nikoo28
@nikoo28 2 месяца назад
Glad you like them!
@evadranuvvuu
@evadranuvvuu 2 месяца назад
if(root == null) { return null; } TreeNode temp=root.left; root.left=root.right; root.right=temp; invertTree(root.left); invertTree(root.right); return root; Sir this one take o(1)space? Then why using queue sir? Please any one explain?
@minnikeswarrao6185
@minnikeswarrao6185 Год назад
Hi sir, First of all big fan of your work🙌 Requesting you to solve "Sum of distances in tree" problem of leetcode... I have gone through many videos but none of them are clear... Looking forward for your explanation 😇
@anushkamathur4050
@anushkamathur4050 Месяц назад
Why are there so less likes on this video, this is so informative. I have seen more likes on stupid content and this quality content is getting lesser likes. Great work Nikhil Bhiaya!
@TamilarasiM-gs8fb
@TamilarasiM-gs8fb Год назад
Thank you so much .After a long search I got clearly explained video
@anirudhv0062
@anirudhv0062 5 месяцев назад
why is the Linked List implementation of the queue being used here? can we use other thing like deque or other implementation of queue also?
@nikoo28
@nikoo28 5 месяцев назад
Yes
@anirudhv0062
@anirudhv0062 5 месяцев назад
@@nikoo28 Thanks! Your explanations are awesome
@quanganh7094
@quanganh7094 10 месяцев назад
thanks, very comprehensible!!
@susmitapatil4847
@susmitapatil4847 4 месяца назад
Very well explained. Thank you so much for such nice content 🎉
@nikoo28
@nikoo28 4 месяца назад
My pleasure 😊
@glaide1500
@glaide1500 2 месяца назад
Man : On all your series, you tried !!! ... Thank you so much as you continue to saves life.
@ascreations1396
@ascreations1396 9 месяцев назад
😃😃😃😃😃😃😃😃😃
@subee128
@subee128 9 месяцев назад
Thanks
@lemui2075
@lemui2075 Год назад
Thank you so much for video with explaination. May I check with you, why you put the keyword "final" in front of Queue ?
@nikoo28
@nikoo28 Год назад
you can remove the "final" keyword if you like. It is not necessary in this implementation. :)
Далее
55. Jump Game
9:06
Просмотров 11
МАЛОЙ ГАИШНИК
00:35
Просмотров 383 тыс.
Invert Binary Tree | Leetcode #226
6:39
Просмотров 56 тыс.
8 patterns to solve 80% Leetcode problems
7:30
Просмотров 378 тыс.
Making an Algorithm Faster
30:08
Просмотров 95 тыс.