Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Leer Task: Printing a Sequence | Section
Practice
Projects
Quizzes & Challenges
Quizzes
Challenges
/
JavaScript Essentials for Beginners - 1768407374405

bookTask: Printing a Sequence

Taak

Swipe to start coding

Write a program that prints the first ten even numbers.

  • Create a for loop with these parameters:
    • Initialization: start i at 1.
    • Condition: continue the loop while i <= 10.
    • Update: increase i by 1 after each iteration.
  • Inside the loop, use console.log to print the value of i * 2. This will display the first ten even numbers (2, 4, 6, …, 20).

Oplossing

Was alles duidelijk?

Hoe kunnen we het verbeteren?

Bedankt voor je feedback!

Sectie 1. Hoofdstuk 68
single

single

Vraag AI

expand

Vraag AI

ChatGPT

Vraag wat u wilt of probeer een van de voorgestelde vragen om onze chat te starten.

close

bookTask: Printing a Sequence

Veeg om het menu te tonen

Taak

Swipe to start coding

Write a program that prints the first ten even numbers.

  • Create a for loop with these parameters:
    • Initialization: start i at 1.
    • Condition: continue the loop while i <= 10.
    • Update: increase i by 1 after each iteration.
  • Inside the loop, use console.log to print the value of i * 2. This will display the first ten even numbers (2, 4, 6, …, 20).

Oplossing

Switch to desktopSchakel over naar desktop voor praktijkervaringGa verder vanaf waar je bent met een van de onderstaande opties
Was alles duidelijk?

Hoe kunnen we het verbeteren?

Bedankt voor je feedback!

Sectie 1. Hoofdstuk 68
single

single

some-alt