This entire playlist is a treasure. Downloaded all the videos and created multiple copies in my PC, my external hard drive and google drive. Cannot risk it losing in case of apocalypse. And whoever you are, a big thank you. You are a GOAT.
@robinsoni47785 жыл бұрын
No, he is not a GOAT, He is a human
@Slim70735 жыл бұрын
@@robinsoni4778 He capitalized GOAT. It stand for Greatest Of All Time.
@ApoorvaRajBhadani5 жыл бұрын
kuch zyada ho gya...............tareef karne ka tarika tera mujhe kuch khas acha nhi laga 😂
@konstantinrebrov6754 жыл бұрын
@@Slim7073 That is ambiguous abbreviation. There could be 100 things it stand for. And "goat" sounds like a bad word.
@danilo27354 жыл бұрын
@@konstantinrebrov675 it's a word used in many places, for example messi is the football goat, jordan the basket goat etc...
@llarn.i51036 ай бұрын
It’s been 10 YEARS since this playlist and people are still watching it, I don’t usually comment but Really Thank you for this masterpiece
@deeepbagadiya8 жыл бұрын
After 2 Years...THis videos Helped the same.....i am sure till many years this videos will keep helping Students
@random-05 жыл бұрын
yes it's still rocking he left us a treasure
@manishpandey38034 жыл бұрын
yes today's date is 30/05/2020
@sudhanshu98313 жыл бұрын
2021 and still the easiest and understandable explanation of ds on yt
@AmanKUMAR-vq1ls3 жыл бұрын
I am here on 20 july 2021
@jatinvashisht42933 жыл бұрын
😂 This aged very well
@narayankaadda7727 жыл бұрын
Hi Sir, I have followed all your BST tutorials. It was very great and clear explanation. Initially I was afraid of learning BST. Now I can say I have learned BST confidently from your explanation. Thank you very much your contribution to helping programmers.
@RAFAHOUSSAM7 ай бұрын
finally i find someone who explain all things with details thank you so much
@Leon-hg1ph4 жыл бұрын
Yooo, this whole concept of BST is freaking amazing, almost magical. Thanks a lot for sharing this mate!
@darshanbhat94579 жыл бұрын
I am a beginner in DS. These videos helped me a lot to understand quickly. Thanks a lot. Please don't stop uploading. Keep going.
@abhilashnair66606 жыл бұрын
He stopped lol
@monikajha35006 жыл бұрын
He is no more in this cruel world :(
@saeem016706 жыл бұрын
@@monikajha3500 what do you mean by that? :|
@noobcoder59885 жыл бұрын
@@monikajha3500 No, he is alive.
@random-05 жыл бұрын
@@noobcoder5988 sorry but sadly he is dead search for it
@prudvi013 жыл бұрын
I'm watching this series after my engineering, these data structures make much more sense now thank you so much
@shelbygt500410 жыл бұрын
mycodeschool Your tutorials are BRILLIANT! Please do continue the series as soon as possible. Would like to see more on Trees, Graphs, Maps, Hash-tables etc.
@Drogon-Gaming4 жыл бұрын
this play list is absolute bonus for every programmer who wants to get good at data structure , Many thanks to CS DOJO for suggesting this !!!!!
@scotfsh50142 жыл бұрын
I'm in tear watching your video sir, the way you spreading knowledge is on god tier, I coundn't been more satisfied with my life without learning from you.Much Love!
@__hannibaal__ Жыл бұрын
Yeah i stop C++ 25 years ago, and i busy with mathematic, until last year, and per chance i step on these videos on C++ and data structure, and he gave me another breath and i start learn what i lost before, very effective __my back ground mathematic help me__ and now i just i have 80% of C++, and data structure 60%, and this second year is planed to make all data structure __special a complex tree with modern C++__ from scratch and both .
@darshpreetsingh20105 жыл бұрын
All videos are great,most important thing is that they are all very interactive and you have worked very hard in making them and teaching us. Thankyou
@AnonymousCoder7 Жыл бұрын
I'm gonna hit Like 👍🏻to every video of this channel coz It Deserves !!
@sarveshp17272 жыл бұрын
This is THE PERFECT explanation of this concept.
@1gouravgg10 жыл бұрын
finally completed the whole DS series :)
@kausshin54044 жыл бұрын
And got placed at google
@prajwalchoudhary48244 жыл бұрын
@@kausshin5404 lol
@HARIHaran-ks7wp3 жыл бұрын
@@kausshin5404 wait, really??
@manishkumargupta86772 жыл бұрын
Congratulations
@shubhammohapatra77663 жыл бұрын
Really, great stuff man. You have helped a lot of people. You should be really proud of yourself.
@chayakumarsedutainment47994 жыл бұрын
You haven't handled the case when current node is leaf node. Yet, still it is an excellent tutorial for DS and I will recommend this to other. I have learnt a lot from you. Thank you so much..
@ganapatibiswas58584 жыл бұрын
It will fall into the current -> right==null case
@sarveshsant13377 жыл бұрын
In Getsuccessor function instead of: "if(current->data < ancestor->data)" we must use :if(current->data data)" To ensure the data less or equal will be found in left subtree. Thanks for sharing your knowledge.
@hughlee56482 жыл бұрын
i think you won't have to check equal condition since in BST, duplicate is not allowed anyways.
@parthkhanna85424 жыл бұрын
Man...U are an inspiration for me.. You are just great.. No words can express your work.. Thanx for helping
@findoc92823 жыл бұрын
Most enjoyable experience i ever had of online learning, so much love and respect.
@iamparitosh3 жыл бұрын
Completed all the 13 Videos on BST I feel like a BST Master and able to complete most Leetcode problems on BST:)
@yuiooiuyyuiooiuyyuio8 жыл бұрын
Hi I'm Kapil, These codes for successor and predecessor seem to work fine. They keep on storing the pointer to nodes whose value is greater than (or less than) the given integer in the path of search for the integer and the latest updated value is our answer. And also when it finds the integer, it doesn't stop, it goes on to find the next greater value (or smaller) by traversing further down the tree. It's a tiny code :) TreeNode* getSuccessor(TreeNode* A, int B) { TreeNode *P=NULL; while(A!=NULL) { if(A->valright; } else if(A->val>B) { P=A; A=A->left; } } return P; TreeNode* getPredecessor(TreeNode* A, int B) { TreeNode *P=NULL; while(A!=NULL) { if(A->valright; } else if(A->val>=B) { A=A->left; } } return P;
@panavsethi30144 жыл бұрын
It actually works fine, the time complexity is also O(h). I wonder why he used such a complex algorithm.
@harinijeyaraman87894 жыл бұрын
Kudos for your efforts in making concepts seem this easy ! Love your channel. Really helpful !!
@sumitsaini16014 жыл бұрын
getSucessor in case II is really insightful and elegant. That sums up this video.
@prashantbacchewar81949 жыл бұрын
Your videos are "the" best Any plan to cover self balancing trees like Red Black or AVL trees
@dr_9204 жыл бұрын
If it is the max element in the BST, it should return null. The video doesn't take this corner case into consideration. Anyway, another really fantastic video. I learned a lot from the whole series. Thank you.
@codingandmathvideos10 жыл бұрын
Impressive. Thanks a million times. You are simply the best.
@sajalagrawal14306 жыл бұрын
Bro u are the best . cleared all doubts
@RahulSharma-hp6hv9 жыл бұрын
Keep it up dude! you deserves appericiation
@rahil_rehan3 жыл бұрын
theNewBoston of Indian software youtubers!
@shubhamgoyal31006 жыл бұрын
if the right subtree is present, the successor will be the node with the minimum value in right subtree else successor will be the node where we took the last left turn while searching for the current node.
@Marko-vb2mi5 жыл бұрын
Dude, you just I locked my brain on this. Thank you so much!
@Roover_sa4 жыл бұрын
brother make an updated playlist of ds-algo with same explanation . i have not words to express who you are
@nitinjaiman10 жыл бұрын
can you make videos on red black trees, greedy algo, kruskal algo and other topics that are in cormen. i went through mit videos i must say you are better than those fancy professors
@saiudaybhaskarmudivarty75027 жыл бұрын
Thanks for the video series. They've been really helpful for me these days. Can you please do a series on Balanced Binary trees and Tries as well. Thanks in advance.
@stage6669 жыл бұрын
your videos are the best i can find. I love u
@monicaslv3239 жыл бұрын
+yoshinosakura Noooo. I love them more. :p
@prabaljainn3 жыл бұрын
love me too
@shradheytripathi75648 жыл бұрын
Sir,I am a big fan of this channel.Please upload videos of some more topics of Data Structures.
Thank you very much...step by step I like that!! Bravoooo!!! wish you could make more videos on computer science
@AbhishekKumar-ff9vg3 жыл бұрын
FOR PREDECESSOR : - CASE 1 : we will have to find max in left subtree of the given node CASE 2: and when left subtree is not available curr = node_given ; ancs = root ; pred = NULL while ( ancs != NULL ) { if( ancs->data < curr->data ) { pred = ans; ancs = ancs->right; } else ancs = ancs->left; } return ancs;
@sumitsaini16017 жыл бұрын
Woh, you did a problem on iterative inorder traversal without stack!
@jonsnow92464 жыл бұрын
This isn't inorder traversal
@ScrappyVids7 жыл бұрын
@mycodeschool, thanks for the video!, but I believe you should create the video for the predeccessor, in the end people use this videos to learn, but also as reference... dont treat us bad :(
@olly7797 жыл бұрын
you have a very good English!
@butlikereally6 жыл бұрын
this is really really helpful. THANK YOU
@shaiksoofi37414 жыл бұрын
Hats off.Its a treasure
@amateurbeginner75387 жыл бұрын
Inorder presecessor code in c : enjoy guys :) struct node* Getpresecessor( struct Node* root , int data ) { // Search the Node - O(h) struct node* current = Find(root,data); if(current == NULL) return NULL; if(current->left != NULL) { //Case 1: Node has right subtree return maxValueNode(current->left); // O(h) } else { //Case 2: No right subtree - O(h) struct node* presecessor = NULL; struct node* ancestor = root; while( ancestor != current ) { if( current -> key > ancestor -> key ) { presecessor = ancestor; // so far this is the deepest node for which current node is in left ancestor = ancestor->right; } else ancestor = ancestor->left; } return presecessor; } } struct node * maxValueNode(struct node* node) { struct node* current = node; /* loop down to find the leftmost leaf */ while (current->right != NULL) current = current->right; return current; }
@AbhishekKumar-yv6ih7 жыл бұрын
// so far this is the deepest node for which current node is in left. correction: left should be right.
@RaviRanjan_ssj49 жыл бұрын
***** you said that you will be making more lessons on problems on Binary Trees and Binary trees in this video. Why did you stop ?
@desihaxor56905 жыл бұрын
his best friend died in a car accident
@wangchi562 Жыл бұрын
bro, please come back!
@niyas096 жыл бұрын
very good explanation
@kautukraj4 жыл бұрын
Very helpful!
@VC-kj9yx5 жыл бұрын
Thank u so much i finally understood this successor thing
@zaneran59338 жыл бұрын
Good analysis!
@HeWhoShalNotBeNamed_4 жыл бұрын
dude, a single optimization to propose, why not maintain the successor while you find the node? if right subtree doesnt exists,we simply return that value.. this way we sorta save the second traversal in else conditon. ideally it would be o(h) + o(h) but when we maintain it, it would turn out to be only o(h) single go. Find could be modified as :- > Node* Find(Node* root,Node* succ, int data){ Node* ancestor = root; while(ancestor->data != data){ if(data < ancestor->data){ succ = ancestor; ancestor = ancestor->left; } else{ ancestor=ancestor->right; } } return ancestor; } so , as soon as else is triggered, we directly return the succ node that we maitained during FInd().
@arunkumargupta19479 жыл бұрын
i really enjoyed while watching each and every videos. can you add some videos of threaded binary tree if possible.............
@kritikasinghal80156 жыл бұрын
sir,please made video on combinations of sum
@manfredoweber35623 жыл бұрын
i dont know if its good practice, but it a different faster implementation in trade off for higher memory requierements Node* successor(Node * root, int data, Node * ancestor=NULL){ //if found, return either right sub or ancestor if(root->data==data){ if(root->right!=NULL)return root->right; else return ancestor; } // search for Node, if call for left sub, give self as arg if (datadata)return successor(root->left, data, root); else return successor(root->right, data, ancestor); }
@worldfromhome40332 жыл бұрын
Thank you is all I can say!
@namangupta25875 жыл бұрын
Plss make more videos on graphs
@SumitKumar-fn3gj5 жыл бұрын
Thank You Sir
@techswissknife28583 жыл бұрын
Hey, great video thanks a lot. I was wondering a few things about the code you wrote: Is it better in C++ to use nullptr instead of the C macro NULL ? Is temp a good variable name? Coud we call the variable "successor" to make clear we're returning the successor? Is this: while(temp->left != NULL_ temp=temp->left; equivalent to: while (temp = temp->left) { ; //do nothing } Which one is a better c++ idiom?
@vasantprabhu3 жыл бұрын
in the else part inside while loop ,we need a "sucessor=ancestor" there too i think (right subtree part)
@vasantprabhu3 жыл бұрын
update : - i am wrong . the code is correct. explanation is at 16:55 . not all nodes will have a successor. there is no successor the right most node.
@rohankademani64063 жыл бұрын
Finally completed !!!
@siddalingammakasbag53606 жыл бұрын
thank you sir it very much cleared way
@scriptkiddie61513 жыл бұрын
This good initiative had a bad end.
@gobibs16 жыл бұрын
pls talk about n-ary tree
@bpunsky10 жыл бұрын
I noticed it's been a while since you uploaded any data structure videos. Will there be more, or is this the end of the line? Also, if you do continue the series, it would be cool to see a hashmap/hashtable implementation.
@mycodeschool10 жыл бұрын
***** No this is not an end. My co-founder who was an amazing friend passed away in an accident and I have not been able to focus much after that. Its been a hit. I am trying to reset things and keep this project going. Expect some videos in this data structures series in August. Video creation is slow and creative process. But 4-5 videos in a month is still something that I can do. -Animesh Nayan Co-founder, MyCodeSchool
@bpunsky10 жыл бұрын
mycodeschool Wow, sorry to hear that. Not much I can really say other than that I feel for you and hope you come out the other side alright. It really makes the lack of videos seem insignificant by comparison, but I'm glad to hear that you are going to continue with your channel - it's very informative and I imagine helpful to a lot of people. Good luck and again, I'm very sorry to hear about your friend.
@1gouravgg10 жыл бұрын
***** in addition, he was the No.1 coder of India!!
@wingzero19128 жыл бұрын
You've been very helpful Animesh for a lot of people out there.
@heenagirdher64436 жыл бұрын
Thanks sir.....
@roshantopno12537 жыл бұрын
great work
@frozentaco1436 жыл бұрын
Great video. But it would have been much clearer if in case2 code, ancestor was named as temp and successor was named as ancestor.
@sheardz63809 жыл бұрын
Thanks
@usama579266 жыл бұрын
thank u bro
@ankitsingh80877 жыл бұрын
Can you add one more lecture on avl tree before graph.. That is the thing which is missing in your lectures
@listlist89823 жыл бұрын
Hi! Your code had an error when I compiled it. The error is in the last line return successor; and says that successor undeclared (first use in this function). I delcared struct node * successor = NULL; at the top but then it doesn't return anything cause its Value is NULL and the value never changes inside the else statement! How can I fix it?
@PROcrastiDRIVESVofficial8 жыл бұрын
Excellent! Thank you.
@gabrielpereiramendes34635 жыл бұрын
Very Good!
@cherrynaresh31117 жыл бұрын
while(ancestor != current) will not work to find inorder successor of a element in right subtree. So if we change it to while(ancestor != null) i think it will work.
@rimpinag63464 жыл бұрын
Plz tell me sir whats ur name?? Really amazing video
@effy12197 жыл бұрын
excellent
@ArjunSoota5 жыл бұрын
GOAT
@---xk4iw9 жыл бұрын
why there are ont avl tree?
@albertpatterson81647 жыл бұрын
I like this.
@namans98037 жыл бұрын
sir , in this we don't have condition to check if the element is largest ,then there will be no successor.Can we use a find max function to check if it is the largest element ? will it affect the time complexity ??
@DevGamerShripadAgashe6 жыл бұрын
AVL tree please
@RP-th8in9 жыл бұрын
what about 11, what case does it fall into
@santwanadutta44885 жыл бұрын
I guess that successor=ancestor, you have to define outside the if block. Am I correct please reply someone.
@meghasyam4276 жыл бұрын
things r getting real tough...
@TonyDaExpert3 жыл бұрын
did he cover AVL trees?
@Blanke-i3h5 жыл бұрын
what is the successor of 27 or 25 in this case?
@amateurbeginner75387 жыл бұрын
u are bossssssss
@arjunpassi99459 жыл бұрын
Can't you traverse (right root and then left) and check if the next node you are going to traverse is the one you are looking the successor for?
@rishigoley35217 жыл бұрын
Complexity would be O(n) for your approach.
@gauravchauhan8734 жыл бұрын
what about AVL and B+ trees
@looploop66125 жыл бұрын
how does it come back from 6 to 8?
@ShivamKhantwal943 жыл бұрын
Deserving ❤️❤️
@musicalive17826 жыл бұрын
Good tutorial, but in your else statement you missed succesor = ancestor;
@harshitadevichopra80976 жыл бұрын
nope bro, if we are going right, we dont have to move the succesor... see from 9:22 again... hope u'll get it
@kashishmiglani65768 жыл бұрын
great
@manojpatial240410 жыл бұрын
share one tut on threaded binary tree if possible ;)
@rudavathvinod59162 жыл бұрын
How to find post order by given data in- order d b e a f c g and pre order a b d e c f g
@alexrcrew19752 жыл бұрын
simply first make the tree after that find post order as simple as that