For Loops
Automate repetitive tasks by telling JavaScript to repeat code a specific number of times.
Why do we need loops?
Imagine you run an online store and need to display 100 products on a page. Would you write `console.log(product1)`, `console.log(product2)`, ... 100 times? Of course not! That would be tedious, error-prone, and impossible to maintain.
Loops let you say: 'Repeat this block of code a certain number of times' or 'Repeat this for every item in a list.' They're one of the most powerful tools in programming because they turn 100 lines of repetitive code into 3.
Every website you use relies on loops. When Twitter displays your timeline, it loops through an array of tweets and renders each one. When Spotify shows your playlist, it loops through the song list. When Google shows search results, it loops through the results array.