PageRenderTime 49ms CodeModel.GetById 22ms RepoModel.GetById 0ms app.codeStats 0ms

/README.md

http://github.com/darrenaustin/euler-clojure
Markdown | 65 lines | 49 code | 16 blank | 0 comment | 0 complexity | 46ef54829afc7f308b48fa1ae64b6223 MD5 | raw file
  1. # euler-clojure
  2. My solutions to the [Project Euler][1] problems written in the
  3. [Clojure][2] programming language. I am doing this for fun and
  4. profit. But mostly fun. It is a great way to learn a new programming
  5. language and excercise some math muscles (although some of the math
  6. involved was new to me).
  7. Given that, these are just my solutions to the problems. There may be
  8. cleaner, or more idiomattic ways to do this in Clojure (if so, please
  9. drop me a line and let me know). I am learning as I go, so some of
  10. the early solutions might be a little off.
  11. ## Spoiler warning
  12. It should go without saying that if you are trying to solve these
  13. problems yourself, looking at my solutions may spoil it for you. Feel
  14. free to use these solutions if you wish... only cheating yourself,
  15. blah, blah.
  16. ## Usage
  17. Currently this project requires Clojure 1.2. I will update it to 1.3
  18. sometime soon. I use `lein swank` to get a REPL up and running with the
  19. right environment setup. To run the solutions:
  20. user> (use 'dma.euler)
  21. user> (euler)
  22. This will run all of the solutions giving the result, whether it was correct
  23. and how long it took (with a warning if it was over a minute... gotta keep
  24. myself honest :).
  25. You can also run just a specific problem by giving the problem number
  26. to the `euler` function:
  27. user> (euler 42)
  28. ## TODO list
  29. * Migrate to 1.4
  30. * Figure out why 87 is now running out of memory.
  31. * Clean up numeric.clj
  32. * Clean up :use clauses to only specify exactly what is being used in
  33. each file
  34. * Solve the rest of the problems :)
  35. ## Problems to migrate from Ruby project
  36. I originally started with Project Euler as a way to learn Ruby. I
  37. have migrated most of my original solutions over to Clojure. Although
  38. in many cases the Clojure solution is very different from how I solved
  39. it in Ruby. Here is my migration TODO list. Problems I have solved
  40. in Ruby, but not yet in Clojure:
  41. * 96
  42. * 111
  43. * 114
  44. * 115
  45. * 116
  46. * 117
  47. * 124
  48. [1]: http://projecteuler.net
  49. [2]: http://clojure.org