Lesson 6 of 11 · 6 min

Loops and events

A loop repeats code so we don't write it many times ("repeat 10 times"). An event is something that triggers code to run — like 'when the green flag is clicked' or 'when a key is pressed'. Events make programs respond to the user.

🔄   ▶️/⌨️

Loops repeat; events trigger code

Let’s try it! ✍️

Question 1 of

🎉

Great job!

You finished this lesson.

Next lesson → All lessons