;; The first three lines of this file were inserted by DrRacket. They record metadata ;; about the language level of this file in a form that our tools can easily process. #reader(lib "htdp-beginner-reader.ss" "lang")((modname lect06) (read-case-sensitive #t) (teachpacks ()) (htdp-settings #(#t constructor repeating-decimal #f #t none #f ()))) ;; What is the *type* (the "signature") of: ; (a) string-ref (string-ref "howdy" 2) ; (b) number->string (number->string (sqrt 144.0)) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; #| The Design Recipe (take 1 -- primitive types only) ------- per function: 4. tests 5. stub : signature, head, description, body 7. complete the body-expression 8. watch your tests pass |# ; Let's write "monogram": ; Given somebody's name, make a monogram (three letters) for them. ; (Might be used at bottom of business letters, or on fancy towels.)