Preorder, Inorder and Postorder in 5 minute | Tree Traversal | Easiest and Shortest Trick

Поділитися
Вставка
  • Опубліковано 4 лип 2024
  • 👉Subscribe to our new channel: / @varunainashots
    Pre-order traversal while duplicating nodes and values can make a complete duplicate of a binary tree. It can also be used to make a prefix expression (Polish notation) from expression trees: traverse the expression tree pre-orderly.
    In-order traversal is very commonly used in binary search trees because it returns values from the underlying set in order, according to the comparator that set up the binary search tree (hence the name).
    Post-order traversal while deleting or freeing nodes and values can delete or free an entire binary tree. It can also generate a postfix representation of a binary tree
    0:00 - Introduction
    1:35 - Complete the given tree
    2:23 - Basic technique
    2:54 - Solution with example
    ►Data Structure (Complete Playlist):
    • Data Structure
    Other subject-wise playlist Links:
    --------------------------------------------------------------------------------------------------------------------------------------
    ► Operating System :
    • Operating System (Comp...
    ►Database Management System:
    • DBMS (Database Managem...
    ► Theory of Computation
    • TOC(Theory of Computat...
    ►Artificial Intelligence:
    • Artificial Intelligenc...
    ►Computer Networks (Complete Playlist):
    • Computer Networks (Com...
    ►Computer Architecture (Complete Playlist):
    • Computer Organization ...
    ►Structured Query Language (SQL):
    • Structured Query Langu...
    ►Discrete Mathematics:
    • Discrete Mathematics
    ►Compiler Design:
    • Compiler Design (Compl...
    ►Number System:
    • Number system
    ►Cloud Computing & BIG Data:
    • Cloud Computing & BIG ...
    ►Software Engineering:
    • Software Engineering
    ►Design and Analysis of algorithms (DAA) (Complete Playlist):
    • Design and Analysis of...
    ►Graph Theory:
    • Graph Theory
    ►Programming in C:
    • C Programming
    ►Digital Logic:
    • Digital Logic (Complet...
    ---------------------------------------------------------------------------------------------------------------------------------------
    Our social media Links:
    ► Subscribe to us on UA-cam: / gatesmashers
    ►Subscribe to our new channel: / @varunainashots
    ► Like our page on Facebook: / gatesmashers
    ► Follow us on Instagram: / gate.smashers
    ► Follow us on Instagram: / varunainashots
    ► Follow us on Telegram: t.me/gatesmashersofficial
    ► Follow us on Threads: www.threads.net/@gate.smashers
    --------------------------------------------------------------------------------------------------------------------------------------
    ►For Any Query, Suggestion or notes contribution:
    Email us at: gatesmashers2018@gmail.com
    #Preorder#Inorder#Postorder#DataStructure

КОМЕНТАРІ • 2,4 тис.

  • @Mr12n2k22
    @Mr12n2k22 11 місяців тому +1565

    Legend is getting ready for tomorrow exam 😂 .. Right!?

  • @sailendraku.biswal3841
    @sailendraku.biswal3841 Рік тому +1757

    5 mins is much better than 4hrs class lecture 😌

  • @ayushraut_07
    @ayushraut_07 3 місяці тому +50

    Bro Dropped The Coldest Explanation Without Giving us Blanket 🥶

  • @sajidmomin9206
    @sajidmomin9206 Рік тому +131

    I am literally laughing , i am just thinking i have just wasted my mind and hours in classroom for understanding this concept which can be easily done through this logic 🤣 thanks a lot sir for this teaching 🌸❤️

  • @mohdsiddiq5752
    @mohdsiddiq5752 2 роки тому +245

    this guy deserves oscar for explaining this clearly

    • @renots2323
      @renots2323 7 місяців тому +5

      Oscar is for acting not teaching LoL

    • @vedbhensdadia
      @vedbhensdadia 6 місяців тому +2

      100% bhai , sir ki ye ek video ne mera half chapter complete ✅ kr diya.
      Love you much sir.🙏🙏

  • @fathimahasnak3816
    @fathimahasnak3816 3 роки тому +92

    If there's one video on the internet that saved my life, it is this! Thankyou.

    • @vareable646
      @vareable646 3 роки тому

      Yes bro same

    • @namomishra1143
      @namomishra1143 3 роки тому +3

      Same..
      It's 1 AM right now and tomorrow I have exam 😂

  • @Knowledgeprecious
    @Knowledgeprecious Рік тому +173

    Never thought that tree traversal can be this much easy.... Amazing
    I wish I had known this technique earlier!!!
    But it's never too late

  • @user-me9xl6wc5w
    @user-me9xl6wc5w 3 місяці тому +14

    aapke charan kaha hai sarkaar .......................... i just have ONLY ONE QUESTION WHY THIS GUY IS STILL UNDERRATED 🤔

  • @sanatnaik7943
    @sanatnaik7943 Рік тому +79

    I spent 1 hour in class trying to understand this but couldn't even solve 1 question. And now after watching this video for 5 minutes, I solved 5 examples in 10 minutes.
    I'm truly grateful to you for this video, sir. You are the best. 🙇🏻‍♂

  • @vaibhavsood5713
    @vaibhavsood5713 2 роки тому +265

    Amazing method! Couldn't find an easier way of doing this! Btw this question is worth 10 marks in our university exam! 😂 And it's doable in 2 minutes using Sir's trick! It's amazing how his video is still helping people after 3 years! A huge round of applause for this amazing teacher 👏👏👏 He helped me with my DBMS subject as well! This comment is to tell him that not just GATE aspirants but college/university students watch him too! I guess majority might be us college students🤣 even though the channel name is Gate Smashers. Once again, a very great and helpful video😇

    • @GateSmashers
      @GateSmashers  2 роки тому +44

      Thank you so much Vaibhav..lots of blessings

    • @vaibhavsood5713
      @vaibhavsood5713 2 роки тому +10

      @@GateSmashers Thank you, Sir! ❤
      Me and my friends watch you a lot! We're doing BCA (2nd Sem exams getting over and looking forward to 3rd Semester)
      If you'd like to give any useful suggestions to us, It will be amazing! 😊

    • @GurpreetSingh-ot3pw
      @GurpreetSingh-ot3pw 2 роки тому +2

      thnku vaibhav and sir for your guidance,i am really thankful ❤

    • @vaibhavsood5713
      @vaibhavsood5713 2 роки тому +3

      @@GurpreetSingh-ot3pw Arre, Maine to kya hi kiya🤣🤣

    • @animesh_6969
      @animesh_6969 2 роки тому

      @@vaibhavsood5713 hm u r laughing to much

  • @sanchibansode
    @sanchibansode 6 місяців тому +14

    None of the youtuber cleared this topic as of you
    This technique needs an Oscar❤
    Much needed before one day of examination
    Thanks alot

  • @vedanshsingh8100
    @vedanshsingh8100 6 місяців тому +4

    i freaking love you man. What a charismatic teaching style. Got it before the video even ended. LEGEND

  • @ashvinshetty5582
    @ashvinshetty5582 3 роки тому +86

    Give this Sir an Oscar for this trick
    Most efficient way to get inorder,preorder,postorder traversal👍👍

  • @rashikale3791
    @rashikale3791 3 роки тому +241

    i am so grateful for this , it's wonderul and 100% efficient in any kind of question. thankyou so much sir !

  • @thisisashi2498
    @thisisashi2498 4 місяці тому +3

    I watched this trick 30 mins before exam and got it right! Can't say enough thank you🤗🥺

  • @SlayMx_Sg
    @SlayMx_Sg Місяць тому +3

    Maja aagya sir .... Aapne mera 2nd semester aasaan bana diya ....learning microprocessors as well from this channel ❤❤

  • @jainamchheda
    @jainamchheda 2 роки тому +108

    THIS IS THE BEST VIDEO TO LEARN TREE TRAVERSALS. I WAS STRUGGLING A LOT IN IT INITIALLY. BUT, AFTER WATCHING SIR'S EXPLANATION I LEARNED IT EVEN BEFORE 6:46 MINUTES!!!!🔥🔥🔥

  • @sanatahir4658
    @sanatahir4658 2 роки тому +18

    i have no words to explain how good you are.... today my final exam at 3:00 pm. and I am preparing just 2 hours before exam ,,, you are AWEESOME TEACHER ... Sir huge respect for you from Pakistan .....

  • @HamzaKhan-ep9qc
    @HamzaKhan-ep9qc 6 місяців тому +2

    sir this trick is soo genius awesome, my teacher spent 1 hr. explaining this yet couldn't convey the message properly.
    its the second time i am watching this video and i am realizing that this is easier than i thought. thankyou soo much sir :)

  • @Desmond113
    @Desmond113 6 місяців тому +3

    love you bro, it was so hard to me to understand this concept, but after watching this video my all doubt's are clear , i cant even express my felling, Thanks

  • @arshidwani6876
    @arshidwani6876 5 років тому +62

    Ur work is appreciable..U deserve much love and respect...Sir I request ur good self that when you will upload the videos of Algorithms and TOC....plz do reply sir...keep up ur hardwork...love from Kashmir

  • @awwnuraaagggg
    @awwnuraaagggg 2 роки тому +10

    This was so good. I will never forget this concept ever again!!!

  • @MuhammadRaqiburRahman
    @MuhammadRaqiburRahman Рік тому +6

    I have seen the video before 20 minutes of my exam and got common and secure 2 MCQ from this!!!
    Again Thanks a lot!

  • @GNESHRWT
    @GNESHRWT 5 місяців тому +2

    I'm truly grateful for your clear explanations! Your videos have been incredibly helpful in breaking down complex concepts. Thank you for sharing your knowledge and making learning so enjoyable.

  • @rishi71095
    @rishi71095 Рік тому +3

    Wow, this 7 min video just knocked it out of the park for me! Best video for traversals made ever! Thank you for this video.

  • @NehaSharma-lr8ej
    @NehaSharma-lr8ej 3 роки тому +9

    this technique is really good and the way you deliver concept to us is just... really speechless. U deserve huge huge respect. commendable

  • @user-kl6dp6oe7d
    @user-kl6dp6oe7d 27 днів тому +1

    I usually don't comment on education channel but this explanation was amazing,Very simple and clear.

  • @harshitsharma1905
    @harshitsharma1905 Рік тому +12

    Thank you so much sir
    May God bless you with millions of subscribers.🥰

  • @snehalbamble7694
    @snehalbamble7694 4 роки тому +74

    Great trick!!!
    never thought it could be done in such a simple way when I was student,😉 I wish I had got this at that time. 😄

  • @apadogwaenchana9036
    @apadogwaenchana9036 3 роки тому +6

    Now that is a technique I've never seen before, thank you! It's very helpful.

  • @yugandharajagtap5380
    @yugandharajagtap5380 6 місяців тому +4

    Legend is learning this in examination hall !

  • @schopenhauerr
    @schopenhauerr 2 роки тому +5

    Thank you so much for explaining our 2 hours long lecture in just 6 minutes very clearly.

  • @muhammadjawadaman4442
    @muhammadjawadaman4442 Рік тому +18

    Respect you sir soo much. You should be awarded for the best teacher.

  • @user-do1ro5eq6w
    @user-do1ro5eq6w 5 місяців тому +1

    what an excellent teaching after seeing your classes i just search for you in every concept

  • @anwayaar
    @anwayaar Рік тому +13

    Thank you so much, sir. This technique helps a lot.

  • @GeekyGrape
    @GeekyGrape 3 роки тому +4

    wow, super helpful for us visual learners! really appreciate the help, thanks so much!

  • @RishiRaj-lz5wk
    @RishiRaj-lz5wk 3 роки тому +8

    Sir u r a genius 💯😎😎!! Nvr thought tht this can b done in sch a simple way...my exms r near & m preparing fr it..grt tym 2 wtch this video 🤩..Hatsoff 2 u sir!!

  • @lordsnow-vg6ek
    @lordsnow-vg6ek 7 місяців тому +2

    This legend is born to make life easy

  • @user-ic1zf6on9j
    @user-ic1zf6on9j Рік тому +5

    I wish we had you as a teacher in our college , thank you so much sir 🙏

  • @sandeepmandrawadkar9133
    @sandeepmandrawadkar9133 5 років тому +37

    Simply superb technique! Hats off to you for simplifying to the simplest possible level 👋👋👋👍👍👍👌👌👌

    • @vinayak186f3
      @vinayak186f3 3 роки тому +1

      EULER'S TRAVERSAL KA NAAM SUNA HAI 😂

  • @user_abhigupta
    @user_abhigupta 2 роки тому +10

    Just after 1 hr my 3rd semester BCA examination will start and I'm so confident after watching this amazing way of finding order
    Thank you so much sir 💖

  • @commanderyadav564
    @commanderyadav564 Місяць тому +1

    Ohh ! Thank you so much sir. I was stuck at this concept for quite a while, but your easy and simple explanation cleared all my doubts. Thank you once again !

  • @AnandRaj-ve7nf
    @AnandRaj-ve7nf 4 місяці тому +1

    Such a great approach, SIR ,it really saves time while written all 3 traversal.❤

  • @praniltamgadge595
    @praniltamgadge595 Рік тому +9

    best technique ever
    I understood at one time
    thanks sir .

  • @Cristiano_Ronaldo2023
    @Cristiano_Ronaldo2023 Рік тому +3

    ❤️❤️ Sir you deserve award for clearing our doubts ❤️❤️

  • @Blackbenstudios
    @Blackbenstudios 10 місяців тому +2

    The best lecture video ever made. You deserve an award

  • @laptoptoshiba520
    @laptoptoshiba520 8 місяців тому

    INSANE!! I watched several videos on traversal of trees,this is the best one!

  • @akshaysav5547
    @akshaysav5547 3 роки тому +4

    Thank you so much for such an amazing technique sir.... You are doing an incredible work for computer science students
    God bless you....

  • @Prem.s51
    @Prem.s51 Рік тому +4

    Amazing man... It really helped me in my ISC board computer

  • @tulas11
    @tulas11 Рік тому

    The best trick ever came across. A big thank you Varun!

  • @janhavipujare
    @janhavipujare Рік тому +1

    This was soo easy to understand
    Now I feel confident enough with tree traversing

  • @Ayush60722
    @Ayush60722 6 місяців тому +10

    Me watching just before 15 min of exam😅

  • @nickbaib1839
    @nickbaib1839 5 років тому +6

    OMG thats the easiest and shortest way really! Thank you so much! Continue the good job!
    Greetings from Greece!

  • @Rahul-rw7mp
    @Rahul-rw7mp Рік тому

    Best solution i have seen for preorder,inorder and post order!

  • @macaaamala
    @macaaamala 10 місяців тому

    YOU ARE THE BEST LITERALLY THANK U SM COULDNT GET BETTER EXPLANATION THAN THIS U ROCK!

  • @gunasanimounika6784
    @gunasanimounika6784 5 років тому +4

    Tq u sir..... Please add more videos on data structures.. It will be helpful... U way of teaching was good... Whenever I listen to your video it is easy to understand

  • @avanideshmukh2650
    @avanideshmukh2650 5 років тому +4

    awesom trick, after seeing this trick,we will never forget preorder....thanku so much sir,for ur guidance and hard work

    • @kishorebardhan3016
      @kishorebardhan3016 3 роки тому

      Mera ek problem solve krke dhogi kya
      Yahi pre order in order ka

  • @MAHESHACADEMY
    @MAHESHACADEMY Рік тому

    10 वर्ष हो गए बीटेक में इसे पढ़े हुए, आज जाके ये एकदम रापचिक, शानदार तरीक़े से समझ आया 🤠😍🙏 दिल से शुक्रिया सर जी आपका 🙏🌱🎋

  • @iqrasadaf9580
    @iqrasadaf9580 3 роки тому +5

    Amazing trick...👏❤ thank you so much sir

  • @SEEMAVERMA-co6wp
    @SEEMAVERMA-co6wp 5 років тому +5

    Superb!!! I had never understand that topic entire my btech...now i got this... thanks

    • @GateSmashers
      @GateSmashers  5 років тому +2

      Thank You for your love and support. Bless you

    • @preyas2198
      @preyas2198 3 роки тому

      Exactly same 😂

  • @nirjalashrestha1685
    @nirjalashrestha1685 9 місяців тому +2

    thankyou so much..This is the easiest way to learn this traversal techniques

  • @codingball
    @codingball 2 місяці тому

    the way you explained it that's amazing

  • @wondrous_autumn
    @wondrous_autumn Рік тому +6

    Thankkkk uuu soon muchhh...❣❣❣
    It's my exam tomorrow and I just confused but your 5 mins made it very clear..🙌

  • @sambedansahooridul1237
    @sambedansahooridul1237 5 місяців тому +13

    legend see before the 1day of exam..................

  • @gamershouse6014
    @gamershouse6014 2 місяці тому

    really great explanation. Made the tough one very simple. Grateful to you.

  • @khushboo7396
    @khushboo7396 3 роки тому +4

    Thank u sooo much sir u made me realise that this concept is very easy and the way you taught is quite wonderful keep up the good work,..... ☺

  • @mrunalmane3047
    @mrunalmane3047 4 роки тому +11

    Thank you very much,sir. Finally I understood this concept by you. I watched many videos before but I learned here quickly and without any confusion.

    • @GateSmashers
      @GateSmashers  4 роки тому +6

      Thank you mrunal Mane for such a lovely feedback..

  • @shaikmohammedadnan5285
    @shaikmohammedadnan5285 6 місяців тому

    THE BEST Traversal video on UA-cam !! 🫡

  • @ghousekhan455
    @ghousekhan455 Рік тому +1

    U made my worry ease... Heartiest thanks to u.

  • @user-bt4zs3hg6s
    @user-bt4zs3hg6s 3 місяці тому

    Thank you so much sir...
    It got me hours to understand and was confused .. But because of you I could understand it in a proper , simpler way 😊

  • @namomishra1143
    @namomishra1143 3 роки тому +6

    Thank you very much sir..
    Kal mera semester exam h
    Thanks a million

  • @pusaikumarm9165
    @pusaikumarm9165 2 роки тому +6

    Literally today 20/04/22 at 9:30am I have my midterm exam ...I saw this content at early morning 5 am ... it was very helpfull ❣️... thank you much sir🙏

  • @mrdeadpool1238
    @mrdeadpool1238 8 місяців тому +1

    Sirrrrr this is the best method i watched other videos but didnt understand but you saved the dayyyyyyyy

  • @naturemagic5
    @naturemagic5 Рік тому

    The word genius is actually made for you sir... God Bless you.. Keep up the good work... Thank you so much

  • @mohammedyounus8264
    @mohammedyounus8264 2 роки тому +3

    Amazing 🤩

  • @sarthakkumar8679
    @sarthakkumar8679 3 роки тому +8

    how can someone dislike this video 2 minute of silence for them

    • @ashishshetty3512
      @ashishshetty3512 3 роки тому +1

      I guess they got years in their eyes and misclicked it

    • @TechnoGaming_141
      @TechnoGaming_141 2 роки тому

      its bot dislikes it is youtube's algorithm to have a balance between likes and dislikes

  • @KunalGaurav-zb4fy
    @KunalGaurav-zb4fy Рік тому +1

    love you sir...ek bar me hi smjh aa gya ...iske phle bht sari videos dekhi thy but aapka ek video batty jala diya 😅❤️❤️❤️

  • @teetanrobotics5363
    @teetanrobotics5363 5 років тому +3

    Khatrnaak technique hai

  • @Sudeshsorout
    @Sudeshsorout 5 років тому +5

    Kis kis layer per kon kon se protocol use hote h g ... Ye video bhi Bana deejiye sir g .... Please please

  • @vertigo_57_42
    @vertigo_57_42 Рік тому

    Thank you for this technique it makes ordering of nodes really simple

  • @lordseventh7
    @lordseventh7 Рік тому

    moj la di bhai is lecture ne yaar ye sikhke dil khush ho gya bhaii. was very confused in this topic you just made me clear.

  • @CreativityandfunwithAtharva07
    @CreativityandfunwithAtharva07 6 місяців тому +4

    Welcome polytechnic boys 😅
    All the best for tomorrow's exam 🎉

  • @Everingo
    @Everingo 7 місяців тому +19

    Before 1 hour of exam 😂😂😂😂

  • @sakshamverma333
    @sakshamverma333 5 місяців тому

    Mind Blowing Explanation
    What an amazing video
    👏👏👏

  • @Liveinwinters
    @Liveinwinters 6 місяців тому +1

    What a trick bro , NO confusion...!!🥰

  • @tuzenlaong1846
    @tuzenlaong1846 3 роки тому +3

    Not sure if its trick or method but you made it really easier 😂

    • @adibahaque9202
      @adibahaque9202 3 роки тому

      Its actually a trick. Not the method. 🤔

  • @sushilkumarsoni757
    @sushilkumarsoni757 Рік тому

    Thankas a lot sir... I was confused in this topic from many days, but now I understand at once through your good explaination..

  • @user-rz3pi2er4r
    @user-rz3pi2er4r 6 місяців тому +1

    Sir you really deserve a award for explaining this topic in an easy way❤

  • @wizard.01
    @wizard.01 10 місяців тому

    Saved my precious time! Thank you sir

  • @vanshikayadav9571
    @vanshikayadav9571 Рік тому

    Whooo kya samjhya hai apne matlab jo mujhe abhi kat samajh nhi aya vo apne sirf 5 min me samajh diya sir you are great

  • @manideep.v8b500
    @manideep.v8b500 7 місяців тому

    So beautiful, so elegant, just looking like a wow... Explanation superb sir😊😅

  • @AreebaIftikhar-ue5wo
    @AreebaIftikhar-ue5wo Рік тому

    Your teaching style is so amazing ❤❤❤❤

  • @baibhabchakraborty8685
    @baibhabchakraborty8685 Рік тому

    It helped me to give answers using a proper method... Thanks a lot👍🏻

  • @piyushjain3027
    @piyushjain3027 Рік тому

    Teaching skills he have is just too good🤗

  • @sanghamitrabehera5805
    @sanghamitrabehera5805 5 місяців тому

    You actually deserve a lot 🎉....tq sir 🙏 i understand my every doubt from your lecture

  • @207bhuvankumar9
    @207bhuvankumar9 5 місяців тому

    one of the best understanding platform , thanks sir

  • @lasyalalu316
    @lasyalalu316 Рік тому

    This man has my whole heart ❤️

  • @padmalochany5226
    @padmalochany5226 4 місяці тому

    Excellent...thank you so much for teaching this

  • @krishnapreetham8325
    @krishnapreetham8325 Рік тому

    Sir,you deserve Massive respect 🙏

  • @allinone8363
    @allinone8363 7 місяців тому +1

    Really sir aapki jitni tareef karenge utni km h 😊 every topic become very easy after watching your videos