Intermediate
Turn round without stopping
Go sends the ball right, Back sends it left. Pressing Back mid-flight makes a new spring that starts from rest.
Change goTo so a second press keeps the ball's speed: one frame after Back, the ball must still be moving forward.
What Check tests
- One frame after the turn-round click the ball still moves forward
- Then it turns round and heads back
- It ends at 0
Stuck? One hint at a time
The solution unlocks after your first Check. Try first: that is where the learning happens.
Runs in your browser. Your code is saved here.
Your page
Press Run to see the page.
animations
0.00s0.10s0.20s0.30s0.40s0.50s0.60s0.70s0.80s0.90s
Nothing is moving yet. Hover, click or scroll the page: every animation it starts shows up here as a track.
frames
Console
Nothing logged yet.