[plt-scheme] Question on Teaching Scheme with DrScheme

From: Jens Axel Søgaard (jensaxel at soegaard.net)
Date: Tue Nov 5 07:44:31 EST 2002

>
>
>On Thursday 31 October 2002 16:30, Lear, Russell wrote:
>  
>
>>Not sure if this is a reasonable request, but here goes...
>>
>>My 12 year old daughter was looking over my shoulder while I was working on
>>something in DrScheme.  She asked questions so we went over the arithmetic
>>operations and did some simple function definitions (computing the area of a
>>circle and using that to compute the volume of a cylinder).  She bought into
>>the lisp notation surprisingly quickly.
>>
>>Anyway, she's pretty excited over this and wants to learn more.  Are there
>>any resources people know of on teaching kids simple programming?  "Scheme
>>and the Art of Computer Programming" wasn't written with 12 year old kids in
>>mind!
>>
Take a look at the turtles teachpack. It is very easy to make nice 
drawings quickly with it.
For instance:

  (turtles)
  (repeat 10
          (draw 100)
          (right 160))

Where I cheated a little. Put these in a seperat teachpack:

; Names taken from COMAL
; (which I was taught in Danish elementary school when I was a kid)

(define forward draw)  
(define (right a)
  (turn (- a)))
(define left turn)

(define-syntax repeat
  (syntax-rules ()
    [(repeat n body ...) (let loop ([m 10])
                         (if (= m 0)
                             (void)
                             (begin
                               body ...
                               (loop (- m 1)))))]))


I used a set of homegrown macros and defines like

    (define frem forward)   ; frem is the danish word for forward

to make an easy turtle language in Danish.  I used it one day a bunch of
potential students visited our school and I had the responsibility to 
show them
that "we have computer science". I think (knock on wood) that the idea was a
success.

-- 
Jens Axel Søgaard






Posted on the users mailing list.