0 of 8 problems solved • 0%
Use in a course

Exercise prompt

Count Down by Two

A loop counter can decrease instead of increase. The update decides how the counter changes after each repetition.

Example

for (let number = 3; number >= 1; number -= 1) { console.log(number); }

Your task

The supplied loop moves from 6 down to 2 in steps of two. Complete its body so the console displays 6, 4, and 2.