From 26e075253809b37df722c1ab4d57f5013d6478bf Mon Sep 17 00:00:00 2001 From: Brian Tripp <46498972+bdtripp@users.noreply.github.com> Date: Sun, 30 Nov 2025 17:08:15 -0600 Subject: [PATCH] fix(curriculum): corrected formula for generating a random number (#64231) --- .../67327217e70ee0db7913b255.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/curriculum/challenges/english/blocks/lecture-working-with-conditional-logic-and-math-methods/67327217e70ee0db7913b255.md b/curriculum/challenges/english/blocks/lecture-working-with-conditional-logic-and-math-methods/67327217e70ee0db7913b255.md index 31ed201a002..a4822598c7b 100644 --- a/curriculum/challenges/english/blocks/lecture-working-with-conditional-logic-and-math-methods/67327217e70ee0db7913b255.md +++ b/curriculum/challenges/english/blocks/lecture-working-with-conditional-logic-and-math-methods/67327217e70ee0db7913b255.md @@ -79,7 +79,7 @@ So, if the decimal point is less than `5`, the number is rounded down. And if th ```js const max = 10; const min = 5; -const randomNum = Math.floor(Math.random() * (max - min)) + min; +const randomNum = Math.floor(Math.random() * (max - min + 1)) + min; console.log(randomNum); ```