Search⌘ K
AI Features

Coding Challenge: Bouncing Ball

Explore how to create a horizontal bouncing ball animation by writing JavaScript code that manipulates elements on the screen. This lesson helps you apply animation techniques and improve your understanding of element movement with JavaScript and CSS.

We'll cover the following...

Problem statement

The goal of this exercise is to make a basketball move across the screen. You can download the ball image from here. Start with the following HTML and CSS content and write the JavaScript code that makes the ball bounce horizontally.