Chez Scheme Transcript [Mon Mar 14 13:48:20 2011] > (cons 3 4) (3 . 4) > (cons '(3) 4) ((3) . 4) > '((3 . 5)("Mike" . 7) ((5) . 8)) ((3 . 5) ("Mike" . 7) ((5) . 8)) > () () > (cons 'a '()) (a) > (cons 'a (cons 'b (cons '(c)))) Error: incorrect number of arguments to #. Type (debug) to enter the debugger. > (cons 'a (cons 'b (cons c '(d)))) Error: variable c is not bound. Type (debug) to enter the debugger. > (cons 'a (cons 'b (cons 'c '(d)))) (a b c d) > (cons 'a (cons 'b (cons 'c 'd))) (a b c . d) > (list? '(a b c)) #t > (list? (cons 'a (cons 'b 'c))) #f > (pair? (cons 'a (cons 'b 'c))) #t > (pair? (cons 'a (cons 'b '()))) #t > (null? '()) #t > (null? (cdr '())) Error in cdr: () is not a pair. Type (debug) to enter the debugger. > (null? (cdr '(a))) #t > (pair? '()) #f > (pair? '(a)) #t > (pair? (cons 'a '())) #t > (cons 'a ()) (a) > (list? '()) #t > (let ([foo (lambda (n) n)]) foo) # > ((let ([foo (lambda (n) n)]) foo) 4) 4 > ((let ([fac (lambda (n) (if (= n 0) 1 (* n (fac (- n 1)))))]) 5) ) Error: attempt to apply non-procedure 5. Type (debug) to enter the debugger. > (load "goo.ss") > (lambda () 3) # > ((lambda () 3)) 3 > ((lambda (n) 3) 77) 3 > ((lambda () 3 4 5)) 5 > ((lambda (n) (+ n 1) (+ n 1) (+ n 1)) 3) 4 > ((lambda () 3 mike 4)) Error: variable mike is not bound. Type (debug) to enter the debugger. > (set! a 3) > a 3 > ((lambda () (set! a 77) (+ 3 4))) 7 > a 77 > (define a 44) > a 44 > (begin (set! a 3) (set! b (+ a 1)) (set! c (* b 5))) > a 3 > b 4 > c 20 > (transcript-off)