gfor loop in javscript code example Example: for loop javascript var i; for (i = 0; i < cars.length; i++) { text += cars[i] + "<br>"; }