Add JavaScript loops and iterations resources (#1604)
* Update 106-javascript-loops-iterations * Update content/roadmaps/106-javascript/content/106-javascript-loops-iterations/readme.md * Update readme.md Co-authored-by: Kamran Ahmed <kamranahmed.se@gmail.com>pull/1657/head
parent
19864b68e5
commit
2b884d483c
1 changed files with 15 additions and 1 deletions
@ -1 +1,15 @@ |
||||
# Javascript loops iterations |
||||
# Loops and Iterations |
||||
|
||||
Loops offer a quick and easy way to do something repeatedly. |
||||
|
||||
You can think of a loop as a computerized version of the game where you tell someone to take X steps in one direction, then Y steps in another. For example, the idea "Go five steps to the east" could be expressed this way as a loop: |
||||
|
||||
``` |
||||
for (let step = 0; step < 5; step++) { |
||||
// Runs 5 times, with values of step 0 through 4. |
||||
console.log('Walking east one step'); |
||||
} |
||||
``` |
||||
|
||||
<ResourceGroupTitle>Free Content</ResourceGroupTitle> |
||||
<BadgeLink colorScheme='blue' badgeText='Read' href='https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Loops_and_iteration'>Loops and iteration</BadgeLink> |
||||
|
Loading…
Reference in new issue