Set 15 - 1D Dynamic Programming
Use Practice Loop if you need a reset.
Problems
| Problem | Difficulty | Pattern | Video |
|---|---|---|---|
| LC 70. Climbing Stairs | Easy | Fibonacci-style | Video |
| LC 746. Min Cost Climbing Stairs | Easy | Min path | Video |
| LC 198. House Robber | Medium | Skip pattern | Video |
| LC 213. House Robber II | Medium | Circular array | Video |
Deliverables
- Write a 1-line invariant for each problem.
- Note 1 edge case or pitfall per problem.
- Record time-to-first-correct solution.
Notes
- LC 70: Fibonacci DP; ways[i]=ways[i-1]+ways[i-2].
- LC 746: dp cost; min of previous two; start at 0/1.
- LC 198: dp[i]=max(dp[i-1], dp[i-2]+num).
- LC 213: run House Robber twice (exclude first/last).
Review
- Time spent + where you got stuck?
- Biggest mistake or missed edge case?
- One concrete improvement for next time.
Comments
Share your approach or ask questions
?
|
Markdown supported
Sign in to post
Loading comments...