//this loops through an array, 'cars', and logs each element to the console.
for (var i = 0; i < cars.length; i++) {
//repeating code here:
console.log(cars[i]);
}
let items = ['beef', 'cabbage', 'javascript']; // Defines a list of items
for (let item of items) { // Defines for loop with a variable of 'item'
console.log(item); // Prints the item that is found
}