Quick actions

cmd+k|ctrl+k

Navigation

Languages

Loop

Snippet info

Language

JavaScript

Visibility

public

Author

faathirfkhrzy

Created

2020-08-29T17:54:36Z

Updated

2020-08-29T17:54:36Z

for(let i = 0; i < 5; i++) {
    console.log(i);
}
console.log("=======");
const myArray = ["Harry", "Ron", "Hermione", "Tom"];
 
for(let i = 0; i < myArray.length; i++) {
    console.log(myArray[i]);
}
console.log("=== For of Loop ===");
let myArrAy = ["Harry", "Ron", "Hermione", "Tom"];
 
for(const arrayItem of myArrAy) {
    console.log(arrayItem)
}
INFO