Skip to content

Instantly share code, notes, and snippets.

@jrslepak
Created July 29, 2014 12:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jrslepak/435f001ab7b3cf92d869 to your computer and use it in GitHub Desktop.
Save jrslepak/435f001ab7b3cf92d869 to your computer and use it in GitHub Desktop.
> (:print-type andmap)
(All (a c d b ...)
(case->
(-> (-> a c : d) (Listof a) c)
(-> (-> a b ... b c) (Listof a) (Listof b) ... b (U True c))))
> (λ ([a : Real]
[b : Symbol]
[c : Boolean]
[d : String])
(and (> a 0)
(not (equal? b 'lolwat))
c
(> (string-length d) 3)))
- : (-> Real Symbol Boolean String Boolean)
#<procedure>
> (andmap
(λ ([a : Real]
[b : Symbol]
[c : Boolean]
[d : String])
(and (> a 0)
(not (equal? b 'lolwat))
c
(> (string-length d) 3)))
(list -1 2 0 5)
(list 'foobar 'xyzzy 'quux 'lolwat)
(list #t #t #f #f)
(list "yes" "sometimes" "no" "why?"))
- : Boolean
#f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment