Created
June 8, 2014 19:33
-
-
Save alexpw/05980266ec3d4dd9714d to your computer and use it in GitHub Desktop.
a data conversion question - https://groups.google.com/forum/#!topic/clojure/140FbQ_bj8g
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(mapcat (fn [[k coll]] (map vector (repeat k) coll)) | |
[[:a [1 2]] [:b [3 4]]]) | |
=> '([:a 1] [:a 2] [:b 3] [:b 4]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment