INPUT r
INPUT a, b
SCREEN 7, , 0, 1
x = a
y = a
sx = 8
sy = 5
WHILE INKEY$ = ""
PCOPY 0, 1
CIRCLE (x, y), r, 0
PAINT (x, y), 0
x = x + sx
y = y + sy
CIRCLE (x, y), r, 15
PAINT (x, y), 15
IF y > b OR y < a THEN sy = -sy: sx = -sx
t = TIMER
WHILE t = TIMER
WEND
WEND