From de3a6eb4dc9bb61d9d11db51c23c3fbd9639d925 Mon Sep 17 00:00:00 2001 From: c0d1ng_ma5ter Date: Thu, 23 Jan 2025 13:19:57 -0600 Subject: [PATCH] fix(curriculum): Add break and default to switch review (#58305) Co-authored-by: Sem Bauke --- .../6723c554025f449f4f39c3f5.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/curriculum/challenges/english/25-front-end-development/review-javascript-comparisons-and-conditionals/6723c554025f449f4f39c3f5.md b/curriculum/challenges/english/25-front-end-development/review-javascript-comparisons-and-conditionals/6723c554025f449f4f39c3f5.md index 0c66d51a192..94e4249f6dd 100644 --- a/curriculum/challenges/english/25-front-end-development/review-javascript-comparisons-and-conditionals/6723c554025f449f4f39c3f5.md +++ b/curriculum/challenges/english/25-front-end-development/review-javascript-comparisons-and-conditionals/6723c554025f449f4f39c3f5.md @@ -28,7 +28,7 @@ console.log(null === undefined); // false ## `switch` Statements -- **Definition**: A `switch` statement evaluates an expression and matches its value against a series of `case` clauses. When a match is found, the code block associated with that case is executed. +- **Definition**: A `switch` statement evaluates an expression and matches its value against a series of `case` clauses. When a match is found, the code block associated with that case is executed. A `break` statement should be placed at the end of each case, to terminate its execution and continue with the next. The `default` case is an optional case and only executes if none of the other cases match. The `default` case is placed at the end of a `switch` statement. ```js const dayOfWeek = 3;