Skip to content

fix(curriculum): align dynamic programming review with Python module - #71557

Merged
majestic-owl448 merged 2 commits into
freeCodeCamp:mainfrom
Rohan-Dedhia:fix/dp-review-align-module
Nov 4, 2026
Merged

majestic-owl448 merged 2 commits into
freeCodeCamp:mainfrom
Rohan-Dedhia:fix/dp-review-align-module

Conversation

@Rohan-Dedhia

Copy link
Copy Markdown
Contributor

Checklist:

Closes #71530

Description

Aligns the Dynamic Programming Review with the concepts taught in the Python module (What Is Dynamic Programming and What Are Some Common Algorithms?):

  • Introduces the climbing stairs problem statement before its recursive, memoization, and tabulation solutions.
  • Compares the exponential \O(2^n)\ naive recursive time complexity with \O(n)\ for memoization and tabulation, contrasting their \O(n)\ space usage and call-stack characteristics.
  • Summarizes the constant-space tabulation optimization (\O(1)\ auxiliary space) retaining only the previous two stair counts.
  • Summarizes the minimum-coin change algorithm using tabulation with denominations [1, 3, 4]\ and target \6, along with \O(amount * number_of_coins)\ time and \O(amount)\ space complexity.
  • Documents common dynamic programming problem patterns (optimization, counting, and decision problems).

@Rohan-Dedhia
Rohan-Dedhia requested a review from a team as a code owner November 3, 2026 09:57
@github-actions github-actions Bot added the scope: curriculum Lessons, Challenges, Projects and other Curricular Content in curriculum directory. label Nov 3, 2026
@majestic-owl448 majestic-owl448 added the python v9 cert These are for issues dealing with the Python V9 certification. label Nov 3, 2026

@majestic-owl448 majestic-owl448 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I corrected the scope of #71530. The request to add a classification of common problem patterns was not justified by the lesson.

Please remove the added "Common Problem Patterns" section. The lesson names these categories in a closing sentence but does not teach decision problems:

Common dynamic programming patterns include optimization problems (finding minimum/maximum values), counting problems (number of ways to achieve something), and decision problems that can be broken down into smaller decisions.

Also replace "Under the arithmetic cost model" with an explicit explanation of the assumptions, such as "Treating each arithmetic operation as constant time and each stored count as one unit of space". The lesson does not introduce the term "arithmetic cost model".

The staircase setup, complexity comparison, constant-space example, and coin-change summary address the four remaining requirements.

@majestic-owl448 majestic-owl448 added the status: waiting update Is awaiting update, after feedback or request for changes label Nov 3, 2026
@Rohan-Dedhia

Copy link
Copy Markdown
Contributor Author

Thanks for the feedback @majestic-owl448! I have removed the 'Common Problem Patterns' section to match the scope of the lesson, and updated the constant-space optimization explanation to explicitly state the assumptions ('Treating each arithmetic operation as constant time and each stored count as one unit of space').

@majestic-owl448 majestic-owl448 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution to the page! 👍
We are happy to accept these changes and look forward to future contributions. 📝

@majestic-owl448
majestic-owl448 merged commit 21f0b63 into freeCodeCamp:main Nov 4, 2026
10 checks passed
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Nov 4, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

python v9 cert These are for issues dealing with the Python V9 certification. scope: curriculum Lessons, Challenges, Projects and other Curricular Content in curriculum directory. status: waiting update Is awaiting update, after feedback or request for changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dynamic Programming Review omits concepts taught in the lesson

2 participants