
Untitled
By:
yeah568 on
Jan 11th, 2014 | syntax:
Scheme | size: 0.33 KB | hits: 42 | expires: Never
;; String -> Boolean
;; determines if string s begins with n
(check-expect (start-with-n? "no") true)
(check-expect (start-with-n? "yes") false)
;(define (start-with-n? s) "") ; this is the stub
;(define (start-with-n? s) ; this is the template
; (... s))
(define (start-with-n? s)
(string=? (substring s 0 1) "n"))