Challenge: Working with the While Loop
Uppgift
Swipe to start coding
-
Create a variable named
iand set it to1. -
Begin a
whileloop that runs for numbers from1to9(inclusive). Inside the loop, do the following:- Print the square of
i; - Increment
iby1.
- Print the square of
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Avsnitt 5. Kapitel 2
single
Fråga AI
Fråga AI
Fråga vad du vill eller prova någon av de föreslagna frågorna för att starta vårt samtal
Awesome!
Completion rate improved to 1.64
Challenge: Working with the While Loop
Svep för att visa menyn
Uppgift
Swipe to start coding
-
Create a variable named
iand set it to1. -
Begin a
whileloop that runs for numbers from1to9(inclusive). Inside the loop, do the following:- Print the square of
i; - Increment
iby1.
- Print the square of
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Avsnitt 5. Kapitel 2
single