Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (def groups [[:rus :uru]
- [:spa :por :ira]
- [:fra :den]
- [:cro :nig :arg]
- [:bra :swi :ser]
- [:mex :ger :swe]
- [:eng :bel]
- [:jap :sen :col]])
- (defn cross [[g1 g2]]
- (for [x g1 y g2] [x y]))
- (defn possible-matchups [groups]
- (->> groups
- (partition 2)
- (mapcat cross)))
- (doseq [matchup (possible-matchups groups)]
- (prn matchup))
Add Comment
Please, Sign In to add comment