Java Binary Search Tree

Поділитися
Вставка
  • Опубліковано 22 гру 2024

КОМЕНТАРІ • 717

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

    Learn in One Videos for Every Programming Language
    Subscribe to Bookmark them: bit.ly/2FWQZTx
    C++ : ua-cam.com/video/Rub-JsjMhWY/v-deo.html
    Python : ua-cam.com/video/N4mEzFDjqtA/v-deo.html
    Java : ua-cam.com/video/n-xAqcBCws4/v-deo.html
    PHP : ua-cam.com/video/7TF00hJI78Y/v-deo.html
    MySQL : ua-cam.com/video/yPu6qV5byu4/v-deo.html
    JavaScript : ua-cam.com/video/fju9ii8YsGs/v-deo.html
    C# : ua-cam.com/video/lisiwUZJXqQ/v-deo.html
    HTML5 : ua-cam.com/video/kDyJN7qQETA/v-deo.html
    CSS3 : ua-cam.com/video/CUxH_rWSI1k/v-deo.html
    JQuery : ua-cam.com/video/BWXggB-T1jQ/v-deo.html
    TypeScript : ua-cam.com/video/-PR_XqW9JJU/v-deo.html
    ECMAScript : ua-cam.com/video/Jakoi0G8lBg/v-deo.html
    Swift : ua-cam.com/video/dKaojOZ-az8/v-deo.html
    R : ua-cam.com/video/s3FozVfd7q4/v-deo.html
    Haskell : ua-cam.com/video/02_H3LjqMr8/v-deo.html
    Handlebars : ua-cam.com/video/4HuAnM6b2d8/v-deo.html
    Bootstrap : ua-cam.com/video/gqOEoUR5RHg/v-deo.html
    Rust : ua-cam.com/video/U1EFgCNLDB8/v-deo.html
    Matlab : ua-cam.com/video/NSSTkkKRabI/v-deo.html
    Arduino : ua-cam.com/video/QO_Jlz1qpDw/v-deo.html
    Crystal : ua-cam.com/video/DxFP-Wjqtsc/v-deo.html
    Emacs : ua-cam.com/video/Iagbv974GlQ/v-deo.html
    Clojure : ua-cam.com/video/ciGyHkDuPAE/v-deo.html
    Shell : ua-cam.com/video/hwrnmQumtPw/v-deo.html
    Perl : ua-cam.com/video/WEghIXs8F6c/v-deo.html
    Perl6 : ua-cam.com/video/l0zPwhgWTgM/v-deo.html
    Elixir : ua-cam.com/video/pBNOavRoNL0/v-deo.html
    D : ua-cam.com/video/rwZFTnf9bDU/v-deo.html
    Fortran : ua-cam.com/video/__2UgFNYgf8/v-deo.html
    LaTeX : ua-cam.com/video/VhmkLrOjLsw/v-deo.html
    F# : ua-cam.com/video/c7eNDJN758U/v-deo.html
    Kotlin : ua-cam.com/video/H_oGi8uuDpA/v-deo.html
    Erlang : ua-cam.com/video/IEhwc2q1zG4/v-deo.html
    Groovy : ua-cam.com/video/B98jc8hdu9g/v-deo.html
    Scala : ua-cam.com/video/DzFt0YkZo8M/v-deo.html
    Lua : ua-cam.com/video/iMacxZQMPXs/v-deo.html
    Ruby : ua-cam.com/video/Dji9ALCgfpM/v-deo.html
    Go : ua-cam.com/video/CF9S4QZuV30/v-deo.html
    Objective C : ua-cam.com/video/5esQqZIJ83g/v-deo.html
    Prolog : ua-cam.com/video/SykxWpFwMGs/v-deo.html
    LISP : ua-cam.com/video/ymSq4wHrqyU/v-deo.html
    Express : ua-cam.com/video/xDCKcNBFsuI/v-deo.html
    Jade : ua-cam.com/video/l5AXcXAP4r8/v-deo.html
    Sass : ua-cam.com/video/wz3kElLbEHE/v-deo.html

    • @SandeepSharma-sr4rj
      @SandeepSharma-sr4rj 5 років тому

      hey thank for the tutorial, it helped me.
      I have a doubt. what is the need for parent element, here is my implementation:
      public class BinaryTree {

      Node root;

      public void addNode(int data){

      Node newNode = new Node(data);

      if(root == null){
      root = newNode;
      }
      else{
      Node currentNode = root;
      while(true){
      if(data

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

      can you explain these declaration please ? Node leftChild , Node rightChild ? how is Node a type ?

  • @XonicDigifact
    @XonicDigifact 11 років тому +225

    When I watch these tutorials my IQ jumps up about 40 points and I feel like I can do anything. Then I go and try to do some things on my own and amazingly, my IQ drops back down to normal lol.

    • @theendurance
      @theendurance 4 роки тому +2

      Beacuse these videos are super basic and dont teach you much lol

    • @XonicDigifact
      @XonicDigifact 4 роки тому +18

      @@theendurance Yet you are still watching them and replying on comments posted 7 years ago? Ooof....

    • @saifullahrahman
      @saifullahrahman 4 роки тому

      @@XonicDigifact i wonder how you are doing now. how much programming do you know'

    • @XonicDigifact
      @XonicDigifact 4 роки тому +8

      @@saifullahrahman Pretty good. I am currently in a product security role doing code review, both blackbox and whitebox / crystalbox. I did however have to go and take college courses on the subject, but I do think watching these videos gave me a decent foundation to succeed. Today, i mostly write Python and Powershell, but i review everything from C and C++, to .NET languages, Java and Assembly (x86/x64 and ARM).

    • @uppalaadarsh3261
      @uppalaadarsh3261 4 роки тому +1

      @@XonicDigifact iam currently out from college, I quite good in java, scala and python. ACC to you ,on which should I focus..

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

    Your tutorials are a gold mine, Even though you speak a bit fast but pausing and listening again and looking into the code with comments helps. almost 9 years later still helping

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

    5 years after making the jump to real money development, I still find myself coming to your videos for interview prep...you've done amazing things for a lot of people

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

    I feel like I have been given everything. I have only ever hoped to live a life with meaning. You guys have given me that. All I can do in return is to try and improve and help more people. I can't imagine to this day that I can actually help as many people as you all say that I do. That is a great blessing that I have received :) Thank you for your kind message.

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

      Thank you Derek.
      From me 7 years later.

  • @KydroxHD
    @KydroxHD 7 років тому

    You are quite literally the only UA-cam algorithms channel that I had to slow down. Thats not a bad thing, everything you say when writing the code is so concise that it makes me want to understand it much more

    • @derekbanas
      @derekbanas  7 років тому

      Thank you for the nice compliment :) I'm the fast tutorial guy I guess

  • @Jpasimio
    @Jpasimio 10 років тому +47

    Thank you! This was so much better than the textbook. Also, your production quality is really good. It is nice to learn from someone who spent more than $5 on their microphone. The animations you used to switch between coding and illustrations were great!

    • @derekbanas
      @derekbanas  10 років тому +7

      Jason Pasimio Thank you for all the nice compliments :) I'm glad you liked the videos.

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

    Thank you for the request :) There are so many things I could cover it is almost never ending. I have to start android and games next. I'll be getting into more best practices and theoretical topics in the future.

  • @derekbanas
    @derekbanas  11 років тому +2

    I'm glad you liked it :) I'm doing my best to finish algorithms this month so I can start android at the beginning of next month. I'll try to get the next part up tomorrow

  • @d3athlygh0st
    @d3athlygh0st 11 років тому +2

    I had a homework on how to do transverses through a tree structure. My teacher never implements code so I can never learned this or really anything else in that class, but I learned this and you did my homework in less than 15 minutes. Thank you so much!

  • @derekbanas
    @derekbanas  11 років тому +4

    Thank you :) Yes sometimes we need to see something a few times for it to sink in. That is why I cram so much information into each video so that you don't have to waste your time

  • @nebilgokdemir4527
    @nebilgokdemir4527 4 роки тому

    I don't have any questions because you already explain everything truly clearly.
    all i wanna say thank you

  • @derekbanas
    @derekbanas  11 років тому +9

    I'm very happy to hear that I was able to help. We all learn in different ways. My presentation style works better for you I guess? I'm very happy to help :)

  • @derekbanas
    @derekbanas  11 років тому +2

    Thank you :) I'm fast just because I wanted to be different from the other videos. I'm working to get better at being fast while maintaining a good speed for people to learn.

  • @khana.713
    @khana.713 6 років тому

    Man, I know that a lot of people probably thank you on daily basis for your videos teaching us how to code. But i felt like expressing my personal thanks to you. If not for you i probably would have not passed 2 of my Data Structures assignments this semester. So thank you from the bottom of my heart and keep at it.

    • @derekbanas
      @derekbanas  6 років тому

      Thank you for taking the time to tell me I've helped :) I greatly appreciate it!

  • @jamesthompson9280
    @jamesthompson9280 6 років тому

    This topic was rushed in my class and I had great difficulty in understanding what a key was. I'd never seen two data types passed in a constructor for the node. so this was super enlightening. I'm so, so happy I found this video!

    • @derekbanas
      @derekbanas  6 років тому

      I'm very happy that it helped :)

  • @jasonmattingly2620
    @jasonmattingly2620 8 років тому

    I don't normally comment on youtube videos but I just wanted to thank you for these. You're a fantastic teacher and when I'm struggling with topics in my java class I inevitably end up here to get your take on things. Hope you feel appreciated for the work you do.

    • @derekbanas
      @derekbanas  8 років тому

      Thank yu for taking the time to tell me they help :) I greatly appreciate it

  • @user-mz1zs4pg5r
    @user-mz1zs4pg5r 8 років тому

    You have no idea how this helped! You explained it better than my lecturer. Thank you.

    • @derekbanas
      @derekbanas  8 років тому

      +Marie J Thank you :) I'm glad I could help

  • @shubhamyeole8746
    @shubhamyeole8746 8 років тому

    This is the best video which help viewer learn BST in just 13:47 mins...
    Duration of video really matters and I think this video was a perfect match for learning BST really very quick...
    Thank you so much for posting this. It was a great help.

    • @derekbanas
      @derekbanas  8 років тому

      Thank you for the compliment :) I'm glad it helped

  • @sarrahwilson8149
    @sarrahwilson8149 7 років тому

    I have 2 classes left in my degree for Information Technology -Networking. I'm practicing as much as possible while working full time. I'm a weak programmer and appreciate this! Almost finished with head first into java book, however my laptop died last night. It was 7 years old.

    • @derekbanas
      @derekbanas  7 років тому +1

      I went through the same things when I was in college and I know it sucks. I went for a year eating nothing but bulk rice and dried pinto beans :( I think life does that to many of us, but when we make it through we are much better for it. Brighter days are waiting for you. I wish you all the best :)

  • @a_stray_dog
    @a_stray_dog 8 років тому

    I've been trying to wrap my head around this concept for a couple of days now, and thanks to your explanation, everything cleared up for me in just a few minutes! Thank you so much!

    • @derekbanas
      @derekbanas  8 років тому

      That's great! I'm happy I could help

  • @derekbanas
    @derekbanas  11 років тому +1

    You're very welcome :) Java does its best to handle the pointer information for you. There actually is no such thing as passing a memory address, but you'll understand it soon since you know C++

  • @JohanSellus
    @JohanSellus 8 років тому

    Really great videos and I particularly like that they are concentrated and fast. Let the viewer decide what can't be understood and go back to that place and re-watch it, instead of everything being slow and not meaningful to everyone. Great job!

    • @derekbanas
      @derekbanas  8 років тому

      +Johan O Thank you :) I do my best to make original videos

  • @VaderDpk
    @VaderDpk 7 років тому

    You're a lifesaver, sir. Just know no matter how old these videos get, you're helping more and more students every coming semester with your tutorials :)

    • @derekbanas
      @derekbanas  7 років тому

      Thank you very much :) It is great to know the videos are helping

  • @MagiRaz
    @MagiRaz 9 років тому

    Sir, you are my freaking hero. It's so much easier to understand when you see application alongside theory instead of one separated from the other.

    • @derekbanas
      @derekbanas  9 років тому

      hybredmoon I'm very happy that I could help :)

  • @derekbanas
    @derekbanas  11 років тому +2

    You're very welcome :) I'm happy that I was able to help

  • @derekbanas
    @derekbanas  11 років тому

    The changes are being made to the node objects. Take a look at the node class. It contains leftChild and rightChild. Based on the situation the leftChild and rightChild nodes are edited

  • @GarraOfTheFunk14
    @GarraOfTheFunk14 9 років тому +1

    Oh my goodness, your video tutorials are BEYOND life saving. You've taught me in 13 minutes what my professor couldn't in an hour. Thanks one thousand times!

    • @derekbanas
      @derekbanas  9 років тому +1

      +GarraOfTheFunk14 Thank you for the compliment :) I'm very happy that I could help.

  • @nhlobane
    @nhlobane 9 років тому +18

    From our school, you are a hero. The best advice you can get from a fellow student about this stuff is a reference to your videos champ. #South Africa->Johannesburg
    The comment comes far. xD :-). Thank you a lot.

    • @derekbanas
      @derekbanas  9 років тому +10

      Mpho nhlobane Wow that is very cool! I have never traveled and it amazes me that people all over the world watch my videos. Thank you for telling me :)

    • @andreasn
      @andreasn 7 років тому

      Norway checking in ! :)

    • @elvissibetyu7228
      @elvissibetyu7228 6 років тому

      From Cape Town about to engage in the vid.

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

    one of the best videos to learn how to code up the insert and traversal of a BST. Thanks, Derek.

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

      Thank you for the nice compliment :) I’m happy I could help

  • @herevancelightena9770
    @herevancelightena9770 4 роки тому +1

    Brilliant!!! It took 9 hours for my professor to explain the whole thing. Brilliant! Luckily they teach this one in math class

    • @derekbanas
      @derekbanas  4 роки тому

      Thank you very much :) I'm happy I could help

  • @patowazhir
    @patowazhir 8 років тому +38

    Brother, you just saved my @ss in my Data Structure class. Thank you @Derek Banas, really awesome video.

    • @derekbanas
      @derekbanas  8 років тому +9

      Thank you :) I'm very happy to be of help

  • @michelleq943
    @michelleq943 11 років тому

    I usually don't bother writing comments but I have to thank you for your awesome and helpful tutorials! Thank you!

  • @derekbanas
    @derekbanas  11 років тому

    We check in the code for the while loop whether the node should be placed on the right or the left. Once we no longer have nodes to check against we call return which throws us out of the while loop. That is why we don't have an infinite loop

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

      The problem is that in your constructor, at the very least, if you tried to create a new node that did not fit one of the if expression logic in the first loop, there is nothing that would allow you to iterate or change any values in your if logic for the second loop and so on. Stackoverflow. There has to be some recursive call (using the argument parameter to pass in the next node to focus on) that iterates your focus node to the correct next node in the tree.
      More simply put. Your constructor will do an infinite loop if it tries to create a leaf past the 2nd branch/from the 3rd branch onwards.

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

      Also, during traversal, there is no mechanism that iterates your focus node back to the parent node. From the root node, recursive calls are made down both branches of the tree. This recursive call repeats at each branch. Once the traversal algorithm reaches a terminal branch aka leaf, it reaches its base case and sends its return value up the call stack. After the calls on that one path are terminated, the calls from a different/right branch begin and so on procedurally.
      So you can think of several "paths" of method calls happening with each path through the tree. Then once these calls resolve at each of their respective leaves, it is up to your algorithms logic to have ordered them precisely to execute in the order that is lowest to highest or whatever.

  • @josephfernando4867
    @josephfernando4867 7 років тому

    You have truly mastered the art of making a concise, knowledge rich tutorial video. Whenever I watch your videos I get inspired to try out the code and it gets me thinking. Thank you once again and looking forward to many more such top quality videos.

    • @derekbanas
      @derekbanas  7 років тому

      Thank you for the compliment :) I'm happy you like the videos

  • @norcal6181
    @norcal6181 8 років тому +17

    These videos are a godsend

    • @derekbanas
      @derekbanas  8 років тому

      +Philthy Phil Thank you :)

  • @derekbanas
    @derekbanas  11 років тому

    Thank you for taking the time to write a nice compliment :) I very much appreciate that and you're very welcome.

  • @derekbanas
    @derekbanas  11 років тому

    Thank you for the nice message :) i have many more tutorials and a new algorithm tutorial coming soon

  • @PEPPERhijaker
    @PEPPERhijaker 7 років тому

    You teach better than my professor, honestly thank you so much. Getting through this class wouldn't be the same

    • @derekbanas
      @derekbanas  7 років тому

      Thank you for the compliment :) I'm glad it helped

  • @Gelgo0g
    @Gelgo0g 9 років тому

    I am so grateful for these videos, they are perfect for revising. Very clear, concise and most importantly to the point.
    Thank you Derek Banas!

    • @derekbanas
      @derekbanas  9 років тому

      Daniel Ball You're very welcome :)

  • @pawanshrivastava7405
    @pawanshrivastava7405 10 років тому

    Derek you are doing a great job ... My first starting point was your Design pattern videos ... and i feel like your design patterns were best in the business .... This one is a top class tutorial for a beginner who can concentrate on the concept and plain code ... Rather those heavy codes which are available in abundance on internet...
    Great Job Sir!!

  • @Plaggard
    @Plaggard 10 років тому

    I plan on acing my data structures exam later this morning thanks to your clear explanations. Thank you for making these awesome videos!

    • @derekbanas
      @derekbanas  10 років тому

      I wish you the best on your exam. You're very welcome :)

    • @Plaggard
      @Plaggard 10 років тому +3

      Got a 98 :)

  • @grifsworld
    @grifsworld 11 років тому

    Easily the most easy to follow and helpful tutorial I've seen on this topic, keep up the good work man!

  • @derekbanas
    @derekbanas  11 років тому

    I may not be understanding the question, but each node needs a key value. That is what separates them and makes them distinct from each other. Does that help?

  • @DeprecatedAPI
    @DeprecatedAPI 7 років тому

    You are the best Derek Banas, thanks for making the lives of students like us much better. God bless you!!!

    • @derekbanas
      @derekbanas  7 років тому

      You're very kind :) May God bless you as well!

  • @derekbanas
    @derekbanas  11 років тому

    Thank you :) I'm happy I could help. All of my videos will always be available for free.

  • @Chr0nalis
    @Chr0nalis 11 років тому +2

    Great! I learned linked lists using your videos , although it took me about 15 watches in between trying to write the code myself to understand it. Wonder how many times I'll be watching this one

    • @derekbanas
      @derekbanas  11 років тому +3

      I'm happy I could help :) Sorry about the speed.

  • @derekbanas
    @derekbanas  11 років тому +2

    Yes a C++ tutorial is coming, but I have to cover C first. To make games I need C and C++ and I plan to make a ton of games

  • @derekbanas
    @derekbanas  11 років тому +1

    Every working environment is different. I was lucky to have a very demanding boss at my first programming employer. He insisted that we all make very detailed sequence diagrams. He also insisted that we write refactored code that was very readable. The ultimate goal is to write code that is readable by anyone. I cover that stuff in my refactoring and object oriented design tutorials

  • @VenomEmperor
    @VenomEmperor 11 років тому

    Thanks a lot! I've never been more interested in studying Java outside of class. This will help me get a little ahead of my class.

  • @derekbanas
    @derekbanas  11 років тому +1

    Thank you :) I'm going to cover graphs and other trees very soon.

  • @ahmaddaroon8965
    @ahmaddaroon8965 5 років тому

    Thanks a lot. It's much better than my teacher. At first it was hard for me, but when i checked the link and watched the Video it became easier, and i learn it so well, and again thank you so much.

    • @derekbanas
      @derekbanas  5 років тому

      Thank you :) I'm very happy that I could help

  • @RedQueenAvenged
    @RedQueenAvenged 9 років тому +8

    Your videos help me out a lot with projects and exam prep. Thank you so much for doing what you do, you magnificent human being.

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

    GD! Mr. Banas, you just got a subscriber. I have yet to find too many videos with people as efficient and concise with the information. Thank you, I have learned a lot from this one video, but it will not be my last.

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

      Thank you very much for the sub and the nice compliment :)

  • @archiliusfowl3701
    @archiliusfowl3701 11 років тому

    You are like the God of Data Structures!!! Hats off dude. And thanks a lot for putting this all together.

  • @derekbanas
    @derekbanas  11 років тому

    toString is used to control what is printed to the screen if print is used on an object

  • @derekbanas
    @derekbanas  11 років тому

    Thank you very much :) I think the speed keeps people awake. I'm trusting that I'm working with intelligent people, which all of you guys are. I'm going to get back into theory topics soon. I'd like to solve all the interview questions in one tutorial. That would be fun

  • @ganeshchandrasekaran5927
    @ganeshchandrasekaran5927 11 років тому +1

    Great tutorial!
    I just have one thing to say, please clarify the difference between BT and BST somewhere in the video because those details are very important to new students who learn by watching such tutorial.
    Binary Tree: Each node can have up to two children, the values of left and right child can be greater or less than parent.
    Binary Search Tree: The value of left child is less than or equal to parent and right child is greater than parent.

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

    First, thanks for your cool videos. addNode has a big flaw. You are assigning the new node to 'parent' which is a local variable and will be destroyed after the method is done. The whole while loop doesn't effect the root node at all since we don't have a reference to it.

  • @billmoney1
    @billmoney1 9 років тому +361

    o thank jesus i found a data structures channel on youtube that has an american speaking in the videos

    • @RaiZRiZ
      @RaiZRiZ 9 років тому +26

      +Tim O Can't understand Indians :P

    • @user-mz1zs4pg5r
      @user-mz1zs4pg5r 8 років тому +1

      Ikr!!

    • @benjaminhenry7497
      @benjaminhenry7497 7 років тому +12

      You are so right!!! No offense to those with accents, after all they speak more than one language, which is one more than I can speak, but I have a hard enough time understanding 0(log N) in English much less in "7-11" !!! lol (I realize that joke dates me, as few people may get the 7-11 reference. But for those that do...:}

    • @edwardelrics2138
      @edwardelrics2138 7 років тому +1

      indian drive me mad dude ==' data structures aint hard as the indian =='

    • @shripalshah100
      @shripalshah100 7 років тому

      public void addNode(int key, string name) {
      if (rootNode == null){
      rootNode = new Node(key, name);
      return;
      }
      Node currentNode = rootNode;
      while(currentNode != null) {
      if(key< currentNode.key){
      currentNode = currentNode.leftChild
      }
      else {
      currentNode = currentNode.rightChild;
      }
      }
      can anyone review this?

  • @derekbanas
    @derekbanas  11 років тому

    Thank you :) Yes I'm not that popular, but that is ok. I tend to make tutorials for people that I assume already know how to program. Most tutorial people tend to talk down to their viewers while I tend to expect them to be intelligent. That's why I really value my community!

  • @msven
    @msven 10 років тому

    Thanks for an awesome video! I'm studying for an interview and this really helped!
    Quick edit...I didn't get the job but am grateful for your videos. Funny enough, I just had a student try to submit your code for one of his homework assignments. I couldn't help but laugh when I saw and recognized the code.

  • @nerminsehic525
    @nerminsehic525 10 років тому +1

    I have exam in like 10 hours, and dude you're saving my ass big time with these tutorials, awesome work.

    • @derekbanas
      @derekbanas  10 років тому

      Nermin Sehic Thank you :) Best of luck on your exam.

  • @sharathkoday3048
    @sharathkoday3048 10 років тому +1

    Its funny that I'm trying to scroll up the video to check the code again thinking its the IDE :P Good job by the way.. subscribed!

    • @derekbanas
      @derekbanas  10 років тому +1

      Thank you very much :) That's funny

  • @fremontleslie431
    @fremontleslie431 11 років тому

    More than these BinaryTrees, I learnt something more important in life.

  • @derekbanas
    @derekbanas  11 років тому

    You're very welcome :) Im very happy to be able to help

  • @astroboomboy
    @astroboomboy 11 років тому

    Also, you have about the best tutorials I have ever seen, I find them to be a bit fast, but then I just watch them more than once. I also like that you provide your code on your website, that helps a lot. I would really like to see more tutorials on more abstract subjects and theory!

  • @derekbanas
    @derekbanas  11 років тому

    Thank you :) It is very nice of you to say that.

  • @ljka
    @ljka 6 років тому

    We appreciate the good lecture, legibility of your codes, as well as Audio/Video quality. Thanks!

  • @0xBK201
    @0xBK201 2 роки тому

    Uni student understanding trees in less than 15 minutes in 2022, rather than from a lecturer. Thank you.

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

      Thank you I'm happy I could help :)

  • @dmacgTV
    @dmacgTV 8 років тому +1

    Great video! However, I think the small distinction between Binary Search Tree and Binary Tree is that with a BST, it has to be ordered (left side is smaller or equal, right side is greater). These restrictions don't exist on a binary tree.
    I really enjoyed the series :)

  • @dreqinwobz4855
    @dreqinwobz4855 11 років тому +1

    I love how you are so multi-talented!

  • @derekbanas
    @derekbanas  11 років тому +1

    Thank you very much :) I greatly appreciate that compliment!

  • @BriefBall
    @BriefBall 9 років тому

    learning this in 'field' is much better than books or slides, Thank you

    • @derekbanas
      @derekbanas  9 років тому +1

      elfassi mounir Thank you :) i'm glad I could help

  • @MrMakemusicmike
    @MrMakemusicmike 6 років тому

    wish I would have watched this before my Google Phone Interview.
    This video is simple and clear.

  • @derekbanas
    @derekbanas  11 років тому

    It is a label of sorts that is unique and is matched to a value

  • @derekbanas
    @derekbanas  11 років тому +1

    Я сделаю все возможное, чтобы следующая часть понятна. Я надеюсь, что это поможет вам в будущем. Существует всегда что-то новое, чтобы узнать

  • @derekbanas
    @derekbanas  11 років тому +1

    Thank you :) I'm actually going to pause this tutorial soon. I agree that lately it has turned into me just writing code and I have found that boring

  • @samirdayalsingh0
    @samirdayalsingh0 9 років тому +1

    helped in my exam at the last moment.
    i just saw the video, and went there and did the program.

    • @derekbanas
      @derekbanas  9 років тому

      Samir dayal singh Great I'm glad I could help :)

  • @chordolive
    @chordolive 11 років тому +1

    You explained everything that my prof explained in 2 hours. Plus I actually understand you better than my prof. How?

  • @derekbanas
    @derekbanas  11 років тому

    They help you pick the right data structures and they teach you how to approach a programming problem. The last reason is probably the most important

  • @derekbanas
    @derekbanas  11 років тому

    I have a link to the code in the description for this video. Sorry if I didn't mention that in the video. I sometimes forget.

  • @derekbanas
    @derekbanas  11 років тому

    What error are you getting?

  • @50rublej187
    @50rublej187 11 років тому

    great job thank you very much iam studing economic informatik and this is excactly what our professor is trying to teach us. Of course i didnt understand all of it by watching it first time you need to watch this a couple of times and do it by yourself

  • @derekbanas
    @derekbanas  11 років тому

    It is just a walk through on how binary trees work. What questions do you have

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

    Hello DEREK! Thank you so much for existing and sharing videos like this. I have no doubt that you are an angel sent from heaven to clarify Binary Tree. 🥰

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

      You are very kind :) It is my pleasure to be able to help.

  • @shatley123
    @shatley123 11 років тому +1

    I'm glad your videos seem to be getting more views lately like they deserve :D

  • @lsyegao
    @lsyegao 10 років тому

    so much better than how my professor explained. Thank you so much!!!:)

    • @derekbanas
      @derekbanas  10 років тому

      So Lee Thank you for the compliment :)

  • @BOND-oc2vi
    @BOND-oc2vi 8 років тому +8

    Great video sir, but could you explain the recursive calling of the preOrder and Inorder methods? How does the program know to keep traversing the leftside of the tree until it points to null? How would it know to go back up the tree? Thanks!

    • @bipinpaudel5817
      @bipinpaudel5817 8 років тому

      Desperately waiting for the same answer.

    • @ninjacell2999
      @ninjacell2999 8 років тому +2

      Remember all the methods are inside each other. It keeps opening new methods until it reaches a method where focusNode is null. Then it finishes, so it pops back out into the method for the node above, prints its value then runs the method for the right child, opening more methods.
      Once it finds a null it still has to finish all the rest of the code inside the methods above.
      If this doesnt help, try writing out everything that is going on.

    • @statphantom
      @statphantom 8 років тому +2

      +Anderson Young recursion is a concept that requires a whole other video to explain, you can kinda see the first method is calling smaller methods in side of it, so using brackets to represent the lifeline of the methods it would be something like this. [Root [rleft [rleftleft][rleftright] ] [rright [rrightleft] [rrightright] ] might be hard to understand but the root method doesn't close until all other methods have been completed

  • @derekbanas
    @derekbanas  11 років тому

    You're very welcome :) I should have made that part of the video more clear

  • @derekbanas
    @derekbanas  11 років тому

    You're welcome. I'll cover deletion next. Then all the other trees will be covered

  • @rajlaxmikatkati7106
    @rajlaxmikatkati7106 10 років тому

    Thank you very much Derek, these tree concepts used to terrorize me, but you have explained it so well that its a cake walk. Would be happy if you could provide some more sessions to learn deep about trees and graphs. And also bitwise operator tricks.

    • @derekbanas
      @derekbanas  10 років тому

      Rajlaxmi Katkati You're very welcome :) I'm planning another advanced algorithm tutorial. I hope to get it going soon.

  • @derekbanas
    @derekbanas  11 років тому

    Thank you very much :) I'm not sure what you mean by soft copy though? I provide a link to the code in the description for the video. Is that what you meant?

  • @derekbanas
    @derekbanas  11 років тому +1

    Thank you :) I'm just happy that I have a nice community! I much prefer having 500 nice people over 10,000 mean people. Thank you for being nice

  • @derekbanas
    @derekbanas  11 років тому

    Yes you are correct

  • @derekbanas
    @derekbanas  11 років тому

    Great I'm glad you found it. I do my best to comment the code.

  • @kshannon6487
    @kshannon6487 10 років тому

    This helped me massively on a project. You are the man!

    • @derekbanas
      @derekbanas  10 років тому

      Great I'm glad I could help :)

  • @CelticSongbird9642
    @CelticSongbird9642 6 років тому

    Thank you for leaving the light on for me to do my assignment!

  • @korm0043
    @korm0043 8 років тому +1

    Wow!! That was amazing! I wish my professor is just as great as you. That was very clear explanation. Thanks a lot!

    • @derekbanas
      @derekbanas  8 років тому +2

      Thank you :) I'm here for free when ever you need me

  • @derekbanas
    @derekbanas  11 років тому

    I plan on covering it when I get back into data structures in the future