Challenge: Using the Range Function
Swipe to start coding
Using a for
loop, print all the numbers from 10
to 20
(inclusive) squared (100
, 121
, 144
, and so on). Make sure your output includes the squares of both the starting number (100
) and the ending number (400
).
Note
The square operator should only be applied in the
for
loop should just iterate from10
to20
.
Løsning
Takk for tilbakemeldingene dine!
single
Spør AI
Spør AI
Spør om hva du vil, eller prøv ett av de foreslåtte spørsmålene for å starte chatten vår
Oppsummer dette kapittelet
Explain code
Explain why doesn't solve task
Awesome!
Completion rate improved to 1.64
Challenge: Using the Range Function
Sveip for å vise menyen
Swipe to start coding
Using a for
loop, print all the numbers from 10
to 20
(inclusive) squared (100
, 121
, 144
, and so on). Make sure your output includes the squares of both the starting number (100
) and the ending number (400
).
Note
The square operator should only be applied in the
for
loop should just iterate from10
to20
.
Løsning
Takk for tilbakemeldingene dine!
Awesome!
Completion rate improved to 1.64single