Play around with the gravity variables and see how they effect the velocity of the ball. Then look at the code to see how the position of the ball is changed on each tick. Could you remix this and add more balls? What if the gravity were not global, but different for each ball, and change according to how close they are to other balls?