The best part about his lectures are that the way he demonstrates things makes our brain automatically figure out why we are doing this and this is what no other channel on UA-cam provides. I'm really thankful to Tushar for making iterative dp my second nature 🙏🏼❤
Thank you Tushar. I am sure that no one have explained Dynamic Programming this simple and straightforward. Even we may not be able understand how the values are filled in the DP array dynamically in other explanations. Most of them are always very simple Fibonacci example or very high level. So, for anyone who would like to understand Dynamic Programming, your videos are the best.
The video that started my interest in dynamic programming. Seen this video 4 years ago in 2017 for the first time and with one example I got the whole idea about Dynamic programming. After that I'm able to solve most of the coding problems using Dynamic Programming approach.
Just wanted to revisit Tushar's videos after completing my employment of 4 years at Google in the Bay Area. big thanks to you Tushar to help me with this and other challenging problems!
Amazing video. Would have taken me an entire day had I gone through online sources. This cleared all the things in less than 10 minutes. Thank you so much!!
Learning how to use a matrix to solve these kinds of questions was a real break through for me. That visualization is better than seeing code, now I can write it any language easily.
well, i don't know how i could pass quizzes without your videos :( I've been using your videos for most of algorithms and they are ease to understand and not time consuming compared to the time i could spend reading the book and sometime don't even understand the pseudo-code itself. THANK YOU, THANK YOU AND THANK YOU ONCE MORE.
You are the best lecturer I currently found on UA-cam to teach hard problem using Advance Technique. No one else can eplain in short, precise & natural as you Tushar !!! > This will always be your punchline "The best we can do WITHOUT". And it's damn easy to understand in Natural Language rather than cold codes.
I wonder how my teachers can explain such simple algorithms in a way that noone understands it. I learned all algorithms from indian students. Thx, I love you man
thank you very much I was able to understand everything. i was able to see how the already computed values were used for the calculation avoiding the redundancy, which is clearly a dynamic programming concept. thank you for such a wonderful video. Hope you help us more.
I think there needs to be more explanation on why there is a max used when the last char don't match. The reason is explained very well in the following section of the wiki page: en.wikipedia.org/wiki/Longest_common_subsequence_problem#Second_property Suppose that the two sequences X and Y do not end in the same symbol. Then the LCS of X and Y is the longer of the two sequences LCS(Xn,Ym-1) and LCS(Xn-1,Ym). To understand this property, consider the two following sequences : sequence X: ABCDEFG (n elements) sequence Y: BCDGK (m elements) The LCS of these two sequences either ends with a G (the last element of sequence X) or does not. Case 1: the LCS ends with a G Then it cannot end with a K. Thus it does not hurt to remove the K from sequence Y: if K were in the LCS, it would be its last character; as a consequence K is not in the LCS. We can then write: LCS(Xn,Ym) = LCS(Xn, Ym-1). Case 2: the LCS does not end with a G Then it does not hurt to remove the G from the sequence X (for the same reason as above). And then we can write: LCS(Xn,Ym) = LCS(Xn-1, Ym). In any case, the LCS we are looking for is one of LCS(Xn, Ym-1) or LCS(Xn-1, Ym). Those two last LCS are both common subsequences to X and Y. LCS(X,Y) is the longest. Thus its value is the longest sequence of LCS(Xn, Ym-1) and LCS(Xn-1, Ym).
I've been looking at lots of lecture notes, tutorials and videos in the Internet to understand DP, but couldn't clearly understand until I watched your video. Your approach of DP is the best I've ever seen and now I'm confident in DP. :)
thank you so much! I wanted to solve a problem related to this but even seeing the solutions i had no idea what they were doing until i saw your explanation!. will make sure to check more videos of yours. ^_^
its our great teachers in colleges who passed this wealth of memorization knowledge with out giving an explanation like this which makes algorithms difficult to learn. I'm not surprised to hear these comments. I'm glad Tushar is doing such a wonderful job here. Kudos to him!!
This is the clearest, complete, and most concise explanation of longest common subseq I've seen so far. Thank you so much!
this is the most sarcastic comment on youtube
Say it again!
Tushar's favorite line - `Yes, we will use dynamic programming to solve this ;)`
please check this playlist : ua-cam.com/play/PLeF0b8iqbx4mogykbd82-HY9Y1-JS9MDr.html
haha I always loved that too.
😂😂😂❤
Love, how knowledgeable and clear as a teacher you are. Absolutely in debt. Much respect
reading wikipedia for ages...
finnaly with your video i do understand the sequence so thank you very much:)
greetings from Germany:)
GameKeppers haha, same situation
please check this playlist : ua-cam.com/play/PLeF0b8iqbx4mogykbd82-HY9Y1-JS9MDr.html
All your videos are just awesome. You explain every detail so clearly . I like that you don't rush the things.
Nothing on the net has made DP more easier..thanks a ton!! :)
The best part about his lectures are that the way he demonstrates things makes our brain automatically figure out why we are doing this and this is what no other channel on UA-cam provides.
I'm really thankful to Tushar for making iterative dp my second nature 🙏🏼❤
Thank you Tushar. I am sure that no one have explained Dynamic Programming this simple and straightforward. Even we may not be able understand how the values are filled in the DP array dynamically in other explanations. Most of them are always very simple Fibonacci example or very high level. So, for anyone who would like to understand Dynamic Programming, your videos are the best.
I learned most of the stuff from your videos, sir. It's quite helpful.Thank you so much.
I still come back to this video years later after tripling my SWE salary, priceless content
Your way of teaching makes me visualise things and I really want to thank you for this.
You are an absolute champion, your answer and explanation was really clear great job.
Thank you so much for this video, you explained it very well! Much appreciated!
The video that started my interest in dynamic programming. Seen this video 4 years ago in 2017 for the first time and with one example I got the whole idea about Dynamic programming. After that I'm able to solve most of the coding problems using Dynamic Programming approach.
Supper clear! After watching your explanation, I am able to finish the code within 5 min! Thank you!
Nicely explained and easy to understand . Thanks a lot!
Just wanted to revisit Tushar's videos after completing my employment of 4 years at Google in the Bay Area. big thanks to you Tushar to help me with this and other challenging problems!
Feels so good to finally understand this, thank you!
took only 8 minutes to explain what most take 20+ minutes. And you did it great. cleared up everything. Thanks
Amazing video. Would have taken me an entire day had I gone through online sources. This cleared all the things in less than 10 minutes. Thank you so much!!
What a fantastic lesson! Thank you, Tushar.
THKS man you just save my Semester
Learning how to use a matrix to solve these kinds of questions was a real break through for me. That visualization is better than seeing code, now I can write it any language easily.
Great explanation, this makes dynamic programming much easier to understand.
well, i don't know how i could pass quizzes without your videos :( I've been using your videos for most of algorithms and they are ease to understand and not time consuming compared to the time i could spend reading the book and sometime don't even understand the pseudo-code itself. THANK YOU, THANK YOU AND THANK YOU ONCE MORE.
Thanks I'm making progress on my interview skills. Awesome tutorials.
Perfect tutorial! You deserve hundred of likes for saving my time 👍🏼
You are the best lecturer I currently found on UA-cam to teach hard problem using Advance Technique. No one else can eplain in short, precise & natural as you Tushar !!!
> This will always be your punchline "The best we can do WITHOUT". And it's damn easy to understand in Natural Language rather than cold codes.
The short lesson make me cleat about LCS problem,Thanks!
I wonder how my teachers can explain such simple algorithms in a way that noone understands it. I learned all algorithms from indian students. Thx, I love you man
Thank you once again for the explanation! You really are a life-saver!
After searching LCS a lot on the web, finally I found an easy explanation. Thanks a lot.
thanx a lot ,simple and effective ,make the problem easy
thank you very much I was able to understand everything.
i was able to see how the already computed values were used for the calculation avoiding the redundancy, which is clearly a dynamic programming concept.
thank you for such a wonderful video. Hope you help us more.
Holy mollie! I finally got it!!!! Thanks for the time you put into this.
One of the Best explanations I have heard so far in coding
Very well explained . Thanks for simplicity!
ive learned alot from your vids of dynamic programming. Thanks man
I'm here 8 years later! I need him to go through all the Leetcode 75! 😃
One of the best explanations I ever saw on this topic !!.... Thank you very much sir 😀 👏🏻👏🏻
i have passed the algorithm subject just by watching your videos... thanks a lot !!
You make every topic very easy to understand. Thanks. :)
Dude, I really like your videos. Super helpful during prep. I hope you're having fun at your workplace but you should consider doing this fulltime ;)
Concise and well explained, didn't really understand this algo too well in DP
Cheers!
This was incredibly helpful! Thank you so much.
You have explained all DP problems very well...thanks a ton :)
Superb explanation .. If i am stuck in any problem then instead of google just finding your solution for the problem is the best thing.. Thanks ..
+1 for explaining DP in such an easy way. Thanks alot
THANK YOU! You saved me! No one on the net has ever explained DP well but you. Keep it up :)
This is the best explanation for LCS problem so far. You are great bro.
Love your videos Tushar ! Thanks ! really appreciate your efforts
Thank you for these videos on Dynamic Programming...
These videos are enjoyable, you rock man
Very clear little tutorial! Nice job and thanks!!
Good tutorial. Very articulate and clear 🙏
I think there needs to be more explanation on why there is a max used when the last char don't match. The reason is explained very well in the following section of the wiki page:
en.wikipedia.org/wiki/Longest_common_subsequence_problem#Second_property
Suppose that the two sequences X and Y do not end in the same symbol. Then the LCS of X and Y is the longer of the two sequences LCS(Xn,Ym-1) and LCS(Xn-1,Ym).
To understand this property, consider the two following sequences :
sequence X: ABCDEFG (n elements)
sequence Y: BCDGK (m elements)
The LCS of these two sequences either ends with a G (the last element of sequence X) or does not.
Case 1: the LCS ends with a G
Then it cannot end with a K. Thus it does not hurt to remove the K from sequence Y: if K were in the LCS, it would be its last character; as a consequence K is not in the LCS. We can then write: LCS(Xn,Ym) = LCS(Xn, Ym-1).
Case 2: the LCS does not end with a G
Then it does not hurt to remove the G from the sequence X (for the same reason as above). And then we can write: LCS(Xn,Ym) = LCS(Xn-1, Ym).
In any case, the LCS we are looking for is one of LCS(Xn, Ym-1) or LCS(Xn-1, Ym). Those two last LCS are both common subsequences to X and Y. LCS(X,Y) is the longest. Thus its value is the longest sequence of LCS(Xn, Ym-1) and LCS(Xn-1, Ym).
This was so easy to learn. Thanks a ton! ❤
your videos are really helpful and you are doing a noble job.
BEST explanation on this topic so far!
Thanks Tushar, you've made it so simple to understand.
I must say your videos are very helpful... I consider only your videos for my Data structure and algorithms exams preparation..
Tushar you are such a good human, thank you a lot
Explained so simply. Thanks a lot.
This is the best reference! :) Thank you very much.
Great explanation of the process, thanks!
Thank you guy. I've just understood how to solve this problem from you :)
By far the best video on this topic.
You made it look some simple tushar!, you are a great teacher., thanks.
Very clear and easy to understand.
Cheers !!!
Thank you so much!!! It really clears the concept!!!!
thanks alot for the videos, helps me alot to understand Dp and Network flow.
thanks again
clear, short explanation. Thank you so much!
Thank you!! This was so clear and concise :)
I've been looking at lots of lecture notes, tutorials and videos in the Internet to understand DP, but couldn't clearly understand until I watched your video. Your approach of DP is the best I've ever seen and now I'm confident in DP. :)
thanks a lot bro
keep making these types videos
very helpful in clearing concepts
thank you so much! I wanted to solve a problem related to this but even seeing the solutions i had no idea what they were doing until i saw your explanation!. will make sure to check more videos of yours. ^_^
Thank you, you really make DP very easy to understand
Thnx a lot... it's so easy to understand and implement and not try to memorize a code When you have Cool teacher like you)) One more time THNX))
do u memorize code generally?
its our great teachers in colleges who passed this wealth of memorization knowledge with out giving an explanation like this which makes algorithms difficult to learn. I'm not surprised to hear these comments. I'm glad Tushar is doing such a wonderful job here. Kudos to him!!
Rudolf Eremyan is this algorithm o(n)?
O(nm)
MILTON KUMAR exactly! And that is not linear time
great video! saved me hours of trying to understand the slideshow from class!
Very good tutorials. Thanks a lot Tushar for the video.
Thanks!! You have made a really nice tutorial.
Great, clear lesson! Thank you!
Thanks alot for this excellent walkthrough.
It is so clear now after watched this video. Thanks!!
Thank you Tushar, your tutorial are great and helped me a lot!
Thank you so much! This video was extremely helpful :-)
once again, thank you for your teaching, it is easier to understand, compared to my professor's teaching
Excellent Explanation. Thank you Tushar!
thanks. simply and clearly defined.
yes sir , your explanation process is very good and I'm very easily understand this tricky concepts
thank you very much sir
Really great video, thank you very much !
Amazing explanation sir!!Thanks a ton.
Clear and to the point! Thanks a ton!
Thanks a lot, your videos are really very nice and clear. Helping me a lot in my Algorithm course.....
the best explanation ever, thank you
The best explanation on LCS
thanks a lot, that's the explanation I was looking for
Thank you! Really clear and helpful!
nailed bro .... thanks I was struggling with this problem .. now it is much clear .
Great video, really helped my understanding. I find it quite difficult to see what algorithms are actually doing just by looking at wikipedia.