Join our Coding Ninjas official telegram community here: t.me/codingninjas_official
@ankitbanerjee48684 жыл бұрын
I was searching for the explanation for this problem on youtube. Believe me, when I say this, this explanation is the best explanation I got.
@durjaarai77373 жыл бұрын
100%
@sankalparora9374 Жыл бұрын
Some people have a knack at explaning stuff, and Ankush Singla is one of them. Thanks for the explanation!
@CodingNinjasIndia Жыл бұрын
Hi @sankalparora9374, Thank you for the kind words! We hope that this video has helped you! Stay tuned to Coding Ninjas KZbin channel for more such content! Do check our Coding Ninjas Studio, where you can upskill for free and become a Ninja Coder: www.codingninjas.com/studio/home? If reading is your preference, you can find top articles to upskill in your career here: www.codingninjas.com/studio/library? If you would like to opt for a Coding Ninjas course, you can check our courses here: www.codingninjas.com/?
@ankitsharma82215 жыл бұрын
Awesome explanation. Just a suggestion: We can store all the values of the inorder in a lookup table and pass it as an argument Won't have to calculate the rootIndex each time :)
@ryan-bo2xi4 жыл бұрын
Excellent explanation ! It deserves more likes .. hats off
@renudixit30874 жыл бұрын
Awesome explanation , you make it so easy to implement, thanku
@SR-we1vl4 жыл бұрын
I've worked out the math for PostOrder Traversal. Is it good to go!? int lInS = inS; int lInE = rootIndex - 1; int rInS = rootIndex + 1; int rInE = inE; int lPoS = poS; int lPoE = lInE - lInS + lPoS; int rPoS = lPoE + 1; int rPoE = poE - 1;
@user-mi8ew2to8e4 жыл бұрын
Ab ja ke mere ko ye samajh me aaya hai...subscribed.
@unmeshguleri53063 жыл бұрын
That was an awesome explanation, it was simple maths as told by you. Thank you for it.
@CodingNinjasIndia Жыл бұрын
Thank you for the kind words! We hope that this video has helped you! Stay tuned to Coding Ninjas KZbin channel for more such content! Do check our Coding Ninjas Studio, where you can upskill for free and become a Ninja Coder: www.codingninjas.com/studio/home? If reading is your preference, you can find top articles to upskill in your career here: www.codingninjas.com/studio/library? If you would like to opt for a Coding Ninjas course, you can check our courses here: www.codingninjas.com/?
@kuldeepnarayanminj4 жыл бұрын
best explaination on youtube
@AbhishekJha-wm5oq3 жыл бұрын
VERY GOOOD EXPLANATION!
@Deepak-jk1eh4 жыл бұрын
very big thank you for this explaining generally i don't like to write comment on video but for this explanation i did this .
@anubhavnema6134 жыл бұрын
Awesome Explanation
@chandrahassoman66485 жыл бұрын
What a nice explanation! Maza aa gaya.
@ankithans59163 жыл бұрын
you made it easy..
@NadinMagdy3 жыл бұрын
Indians if you're gonna talk hindi in the video, just WRITE IT IN THE TITLE
@gamingparlour17325 жыл бұрын
ek number sir
@MrPranavsss5 жыл бұрын
Great Explanation. Followed every bit of it. Thank you so much for this :)
@prakashshukla35583 жыл бұрын
Super cool awesome video , i will try to make video as good as this one.
@Sushil28745 жыл бұрын
Awesome explanation ...!!
@shubhiaggarwal78736 жыл бұрын
The following list of letters are inserted into an empty bst:J,R,D,GT,E,M,H,P,A,F,QFIND final tree.....sir please tell me answer with explaination
@TW-uk1xi4 жыл бұрын
It can be done in more easy way. You are using so many variable unnecessarily which makes code messed up. And this will be slow since you are searching root index every single time.
@sankalparora9374 Жыл бұрын
Root to dhoondna hi padega...
@sankalparora9374 Жыл бұрын
Zyada variables make code look way easier than the other implementations jisme only the seasoned tree developers can understand things.
@awaisakhtar11393 жыл бұрын
We are finding the root using a loop so maybe in case of duplicate values, it might not give us the desired output. Any solution to this?
@abilashg38626 жыл бұрын
Sir , this is which kind of recursion?? top to bottom (or) bottom to top
@sahazeerks23635 жыл бұрын
top down recursion
@rethink20s5 жыл бұрын
This code is working fine in eclipse ide..but I tried this code in compititive programming console is showing stack overflow
@soham27323 жыл бұрын
Really cool explanation 🤟🏻 .. Thanks :)
@CodingNinjasIndia Жыл бұрын
Thank you for the kind words! We hope that this video has helped you! Stay tuned to Coding Ninjas KZbin channel for more such content! Do check our Coding Ninjas Studio, where you can upskill for free and become a Ninja Coder: www.codingninjas.com/studio/home? If reading is your preference, you can find top articles to upskill in your career here: www.codingninjas.com/studio/library? If you would like to opt for a Coding Ninjas course, you can check our courses here: www.codingninjas.com/?
@shivammaheshwari84654 жыл бұрын
Great Explanation, best on youtube
@devendrameena25406 жыл бұрын
awesome explanation dude.. you've got a new subscriber!!
@questtech29794 жыл бұрын
sorry to say that but your solution doesn't work on leetcode. but however explanation is great
@drishtipoddar90654 жыл бұрын
Sir has mentioned that he is assuming the length to be the same. Maybe the program in leetcode has different lengths of arrays of inorder and preorder. Or maybe leetcode has repetitive inputs.
@diveshrajput5724 жыл бұрын
@@drishtipoddar9065 or may be he don't know how to type on keyboard.
@drishtipoddar90654 жыл бұрын
Divesh rajput or maybe u don’t know the English language to frame a correct sentence
@aneesaziz36114 жыл бұрын
left preorder end computation not clear to me. can anybody plz explain? Thanks
@shethnisarg30496 жыл бұрын
just one word WOW!
@karthikk58956 жыл бұрын
What's the running time complexity of this algorithm?
@ankitsharma82215 жыл бұрын
O(n * n)
@Sauravgpt344 жыл бұрын
Thank you so much sir. How can get your complete course?
@ajaytyagi30184 жыл бұрын
nice
@ritikgupta52404 жыл бұрын
print tree function kaise banaya ?
@alphabeta62723 жыл бұрын
satisfaction
@4Dgenius4 жыл бұрын
What language is it? Half english half Hindi?
@kunalkumarshrivastava4 жыл бұрын
yes
@tanmayjain58214 жыл бұрын
Noice
@yayyy58664 жыл бұрын
not a good solution ....not sagtisf time complexity
@MustafaKHAN-sw1xb6 жыл бұрын
Sir mujhai competitive programming ka course karna hai
@Sanjeev.Network6 жыл бұрын
Yes, Coding Ninjas Do have competitive programming Online Classes. Taught by STANFORD and FACEBOOK, AMAZON, MICROSOFT EMPLOYEE. You can go to the below link and have discount of Rupees 1200/- codingninjas.in/app/invite/ZVUAQ
@Sanjeev.Network6 жыл бұрын
Yes, Coding Ninjas Do have competitive programming Online Classes. Taught by STANFORD and FACEBOOK, AMAZON, MICROSOFT EMPLOYEE. You can go to the below link and have discount of Rupees 1200/- codingninjas.in/app/invite/ZVUAQ