From 3441c404bed63c3de20b526c86cfdbb359bc3fb3 Mon Sep 17 00:00:00 2001 From: dfernandezramos Date: Mon, 1 Aug 2022 20:22:47 +0200 Subject: [PATCH] Fix typo on loop definitions --- 2-js-basics/4-arrays-loops/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/2-js-basics/4-arrays-loops/README.md b/2-js-basics/4-arrays-loops/README.md index 89c3cdf9..5a9c95db 100644 --- a/2-js-basics/4-arrays-loops/README.md +++ b/2-js-basics/4-arrays-loops/README.md @@ -74,7 +74,7 @@ Loops allow for repetitive or **iterative** tasks, and can save a lot of time an The `for` loop requires 3 parts to iterate: - `counter` A variable that is typically initialized with a number that counts the number of iterations -- `condition` Expression that uses comparison operators to cause the loop to stop when `true` +- `condition` Expression that uses comparison operators to cause the loop to stop when `false` - `iteration-expression` Runs at the end of each iteration, typically used to change the counter value ```javascript @@ -88,7 +88,7 @@ for (let i = 0; i < 10; i++) { ### While loop -Unlike the syntax for the `for` loop, `while` loops only require a condition that will stop the loop when `true`. Conditions in loops usually rely on other values like counters, and must be managed during the loop. Starting values for counters must be created outside the loop, and any expressions to meet a condition, including changing the counter must be maintained inside the loop. +Unlike the syntax for the `for` loop, `while` loops only require a condition that will stop the loop when `false`. Conditions in loops usually rely on other values like counters, and must be managed during the loop. Starting values for counters must be created outside the loop, and any expressions to meet a condition, including changing the counter must be maintained inside the loop. ```javascript //Counting up to 10