;;; Scheme Recursive Art Contest Entry ;;; ;;; Please do not include your name or personal info in this file. ;;; ;;; Title: Rainin' ones and zeros ;;; ;;; Description: ;;; Don't want my data ;;; in a cloud. What if it rains? ;;; Backup in other clouds. (define (draw) (speed 0) ;(hideturtle) (color "blue") (bgcolor "lightblue") (penup) (forward 200) (left 90) (forward 200) (right 90) (pendown) (cloud 0) (left 180) (penup) (forward 100) (rain) (rain) (right 180) (forward 50) (right 180) (rain) (rain) (right 180) (forward 80) (right 180) (rain) (exitonclick) ) (define (rain) (pendown) (one 0) (penup) (left 180) (forward 330) (left 90) (forward 6) (left 90) (pendown) (zero 0) (penup) (left 180) (forward 350) (right 90) (forward 40) (right 90) ) (define (one x) (pendown) (cond ((< x 10) (forward 10) (penup) (forward 25) (pendown) (one (+ x 1)) ) (else) ) ) (define (zero x) (cond ((< x 10) (circle 6 360) (penup) (forward 36) (pendown) (zero (+ x 1)) ) (else) ) ) (define (cloud x) (cond ((< x 4) (draw_circle) (left 180) (cloud (+ x 1)) ) ((< x 5) (right 45) (draw_circle) (left 90) (cloud (+ x 1)) ) ((< x 6) (draw_circle) (left 135) (cloud (+ x 1)) ) ((< x 10) (draw_circle) (left 180) (cloud (+ x 1)) ) ((< x 11) (right 45) (draw_circle) (left 90) (cloud (+ x 1)) ) ((< x 12) (draw_circle) (left 135) (cloud (+ x 1)) ) (else) ) ) (define (draw_circle) (circle -20 180) ) ; Please leave this last line alone. You may add additional procedures above ; this line. (draw)