how to do a for lopo in js code example
Example 1: forloop in js
for(i = 0; i < x; ++i){
//Loop, x can be replaced with any integer;
}
Example 2: how to make a javascript for loop
var tops = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144];
for (let i = 0; i < tops.length; i++) {
document.write(tops[i] + "tops");
}