educative.io

House Robber: DP or Backtracking?

In the DP intro, the course asks whether we should use DP or another pattern to solve the House Robber problem. In the previous chapter, we solved this using Backtracking, I assume optimally, so I selected Some Other Pattern, but this was incorrect. If the Backtracking solution was sub-optimal, I recommend considering a different problem to teach the Backtracking pattern. If our Backtracking solution was optimal, and this question refers to a different House Robber problem, I recommend specifying further in the quiz question.


Course: Grokking Coding Interview Patterns in Python - Learn Interactively
Lesson: Dynamic Programming: Introduction - Grokking Coding Interview Patterns in Python

1 Like

Hello @Isaac_Haseley,

Thank you for your feedback. Your query is valid, we’ll carefully review the lessons and incorporate any edits that can remove confusion for our learners. Feel free to reach out to us in case of further queries.

Happy learning!