Skip to content

Instantly share code, notes, and snippets.

@jgreco
Created September 14, 2019 06:18
Show Gist options
  • Save jgreco/16e43b5452aa67a6f377aa31f465493b to your computer and use it in GitHub Desktop.
Save jgreco/16e43b5452aa67a6f377aa31f465493b to your computer and use it in GitHub Desktop.
(define (rmap proc target)
(cond
[(list? target) (map (curry rmap proc) target)]
[(vector? target) (vector-map (curry rmap proc) target)]
[else (proc target)]))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment