20 numbered balls, hand-written collisions Gravity, air friction, ball-ball contact, and rotating-wall impulses are solved directly in JavaScript.