0Pricing
Javascript for Kids · Lesson

Waiting with setTimeout

Pause between numbers.

Wait For It... ⏱️

A real countdown waits one second between numbers! We use setTimeout to make the computer wait. ⏱️

console.log('Let us learn to wait! ⏱️')

What Is setTimeout? ⏰

setTimeout runs some code AFTER waiting a number of milliseconds. 1000 ms = 1 second! ⏰

setTimeout(function () {
  console.log('One second passed! ⏰')
}, 1000)

All lessons in this course

  1. Counting Down to Zero
  2. Waiting with setTimeout
  3. Blast Off!
  4. Your Own Timer
← Back to Javascript for Kids