Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

for of javascript

let arr = ["a", "b", "c"]

for (let i in arr){
  console.log(i) // 0, 1, 2
}

for(let i of arr){
  console.log(i) // a, b, c
}
 
PREVIOUS NEXT
Tagged: #javascript
ADD COMMENT
Topic
Name
6+5 =