File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -507,7 +507,8 @@ Loops are used to perform a group of statements a number of times until a condit
507507
508508#### While Statement
509509
510- The while statement is the simplest conditional statement. It repeats a group of statements while the condition it evaluates is false.
510+ The while statement is the simplest conditional statement. It repeats a group of statements while the
511+ condition it evaluates is false.
511512
512513```js
513514let n = 0;
@@ -516,7 +517,18 @@ while(n < 10) { // conditional loop
516517 n++;
517518}
518519```
520+ #### Until Statement
519521
522+ The until statement is similar to the while statement but loops while the condition is false. It repeats
523+ a group of statements until the condition it evaluates is true.
524+
525+ ```js
526+ let n = 0;
527+
528+ until(n >= 10) { // conditional loop
529+ n++;
530+ }
531+ ```
520532#### For Statement
521533
522534The for statement is typically used to count over a range of numeric values. It contains three parts, a
You can’t perform that action at this time.
0 commit comments