Created
May 25, 2011 21:23
-
-
Save jneira/992016 to your computer and use it in GitHub Desktop.
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
(defn triangle-min-path [tr] | |
(first (reduce | |
(fn [p n] | |
(let [mins (map min p (rest p))] | |
(map + mins n))) | |
(reverse tr)))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment