Must first define CIRCLE (with a variable), since we will use it in BUBBLES.
TO CIRCLE :X
REPEAT 90[FD :X RT 4]
END
Plan for BUBBLES:
three times: make a circle, move to the next circle starting place
Note: in the sample below, a circle and a half-circle are used to position the turtle for the next circle. Another procedure, HALFCIRCLE :B is used for this purpose. It completes a half circle, then points the turtle straight up for the next one.
TO HALFCIRCLE :B
REPEAT 45[FD :B RT 4]
SETHEADING 0
END
TO BUBBLES
CIRCLE 2
HALFCIRCLE 2
CIRCLE 1.5
HALFCIRCLE 1.5
CIRCLE 1
HALFCIRCLE 1
END