Master Data Structures & Algorithms For FREE at AlgoMap.io!
@wanzhaocheng8973Ай бұрын
love how you showed all three approaches in the code! really helped me understand the essence of DP solution
@balaganesh344024 күн бұрын
That was the most simplest break down of this problem! Cant thank you enough!
@MamuuhАй бұрын
This is the best explanation I’ve seen. So much clearer now, thank you!
@calebghirmai64783 ай бұрын
Big thanks for taking the time to make this video! You broke down the concepts of DP in a helpful way :)
@GregHogg3 ай бұрын
Glad to hear it!
@krishhhhh367710 күн бұрын
Great way to explain Dp🎉
@christianjt70183 ай бұрын
Nice to see both the Top down and Bottom up solutions. I think bottom up solution is more intuitive in this case.
@GregHogg3 ай бұрын
I think so too :)
@shaunakchaudhary217822 күн бұрын
One quick question. I got really confused on which value do we select exactly. How do we decide on which value to start with initially?
@SHIHJUIheh3 ай бұрын
So impressive! Thanks for providing multiple solutions for DP
@GregHogg3 ай бұрын
You're welcome 🙂🙂
@Azyrys5 ай бұрын
You're amazing at explaining things :D Big thanks for the content.
@trh786fed2 ай бұрын
By looking to all these comments it seems like im the only one who didn't understand
@AdityaGupta-wz9di15 күн бұрын
your explanation is soooo good damn you explained it in such an easy way thanks
@mairahmed6196Ай бұрын
Man I was having such a hard time figuring this out Thank you so much for this video man
@GregHoggАй бұрын
You're very welcome!
@denizmetzger74105 ай бұрын
... as always... impressive and absolutely well explained! 💪🏻👍🏻
@GregHogg5 ай бұрын
Awesome, very glad to hear it :)
@insoucyant29 күн бұрын
Thank You!
@NikerB5 ай бұрын
Great explantation, how long have you been coding?
@GregHogg5 ай бұрын
Thank you! Several years
@rajendrabrahmbhatt25855 ай бұрын
Which software are you using to draw the solution ? Is this OneNote?
@GregHogg5 ай бұрын
Miro
@xingyuxiang16375 ай бұрын
You can start from index 0, and for each associated element, select and unselect. If selected, move 2 steps. If unselected, move to the next step. In this way, you do not need to reverse or start from n - 1.
@GregHogg5 ай бұрын
We start from n-1 in the top down solution and start from 0 in the bottom up solution
@nathanxie11944 ай бұрын
this was such a good explanaition but im still lost lmfao
@lakh0402 ай бұрын
same
@shakilahmed46475 ай бұрын
Impressive Greg!
@GregHogg5 ай бұрын
Thank you!
@codewithtm5445 ай бұрын
I want to learn dsa in python so how can I start please guide me
@GregHogg5 ай бұрын
I have a full playlist of problem solutions
@Fam-m4i3 ай бұрын
Dude you made it complicated 😅. It’s an easy problem
@yashpokar2 ай бұрын
Line number 8-11 is unnecessary. Your explanation 🫡🫡🫡
@AnnShi-c1v18 күн бұрын
tysm omg
@rajgarimella6265 ай бұрын
Why can’t you just take the max of the sum of the even and odd indices?
@mortsaidmort5 ай бұрын
Because skipping two houses can be good, a la [10, 5, 5, 10] where 20 is the best score
@jakewood19425 ай бұрын
Please tell me freshman computer science will be this interesting 😅
@TuanNguyen-ed9rb3 ай бұрын
yep, more interesting than this lol. Sometimes it's so interesting, you just want to smash your computer
@kubs116211 күн бұрын
If you’re asking it probably wont
@legobuildingsrewiew75385 ай бұрын
What about cases where the end of the array had something like 100 or another array where skipping two houses would be optimal? This algorithm doesnt seem to work here right?