Worksheet #1 Basic Expressions Michael Collins (modified from Tony Eng)Basic Expressions:=====================================================================scheme expression kind of expr value78.5"hello"#ty+(+ 3 5)(+ 5 7 -8)(- (* (+ 6 1)(/ 10 4))(- 10 8))(define w "who")w(string? w)Define Special Form======================================================================(define x 5)(define y (+ x 3))xy(define x 7)xy1Basic Expressions: more practice=====================================================================(* 3 4 0)(= 5 (/ 10 2))(> 7 3)(* 5 (> 7 3))(+)(10)(3 + 5)(/ 8 0)(+ 3 y)(+ 3 (define x 5))Basic Expressions: more practice II====================================================================="(+ 3 4)"(+ 19 "30")(* *)(+ (/ 10 0) (8) )not(not (= 3 4))If: what is the value of the following expressions?======================================================================(if #t 1 0)(if (> 7 3) 1 0)(if (and (> 7 3) (< 4 2)) 1 0)More on if: What is the value of the following expressions?======================================================================(if #t 1 yyy)(if #f 1
View Full Document