;(let ((x 1)(y 2))(list x y)) ;"-----------------------------" ;(define var 100) ;(define z 100) ;(case #\a ; ((#\a) 1) ; ((#\b) 2) ; (else 3)) ;(define (++ x)(+ x 1)) ;(set! z (+ z 34)) ; mdo: int int function => loop ; takes a start, end value and a function that ; takes the current count ; ex: (mdo 0 10 (lambda (x)(display (sqrt x))(newline))) ;(newline) (define (mdo start end func) (do ((i start (+ i 1))) ((>= i end)) (func i))) ; lopes: function(lambda) + argument => result (define (lopes longLambda numberOfPlayers) (longLambda numberOfPlayers)) (define (dummy x) x) (lopes (lambda (x) (- x 1)) 5) (define (charles v2 t1 t2) (* v2 (/ (+ t2 273) (+ t1 273)))) (define (pokemon numCaught) (if (= numCaught 151) "You caught them all!" (cond ((> numCaught 151 ) "Wrong Region") ((= numCaught 150 ) "F'n Mew") ((> numCaught 130 ) "So Close!!!") ((> numCaught 100 ) "Try Harder") ((> numCaught 75 ) "Halfish") ((> numCaught 50 ) "Ok, this is sad") ((> numCaught 25 ) "Your an embarisment to Pkmn trainers") ((> numCaught 10 ) "Terrible, you should be killed") (else "Your uncatorgizably bad"))))