In Racket, you can return multiple values from a function by doing, for example,
(define (foo) (values 1 2 3))
Then we can bind them by doing
(define-values (one two three) (foo))
Now one bound to 1 , two to 2 and three to 3 .
I have a function that returns multiple values, but I'm only interested in some of them. Is there a way to extract the “interesting” return values, while the “ignoring” (i.e., not binding) else is a la _ pattern in Haskell?
abeln source share