Skip to content

Instantly share code, notes, and snippets.

@smee
Created November 7, 2011 18:37
Show Gist options
  • Save smee/1345769 to your computer and use it in GitHub Desktop.
Save smee/1345769 to your computer and use it in GitHub Desktop.
problem 79 temp
(fn [coll] (reduce (fn [l c] (map + c (map (partial min) (partition 2 1 l)))) (reverse coll)))
problem 132 (oome)
(fn [pred sep coll]
(flatten
(for [[a b] (partition 2 1 (concat coll [(last coll)]))]
(if (pred a b) [a sep] a))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment