euler-clojure

所属分类:数学计算
开发工具:Clojure
文件大小:135KB
下载次数:0
上传日期:2017-09-30 21:56:07
上 传 者sh-1993
说明:  Darren用Clojure编程语言编写的Project Euler问题的解决方案。
(Darren s solutions to Project Euler problems written in the Clojure programming language.)

文件列表:
data (0, 2017-10-01)
data\base_exp.txt (13884, 2017-10-01)
data\cipher1.txt (3203, 2017-10-01)
data\keylog.txt (200, 2017-10-01)
data\matrix.txt (31305, 2017-10-01)
data\names.txt (46447, 2017-10-01)
data\network.txt (5174, 2017-10-01)
data\poker.txt (30000, 2017-10-01)
data\roman.txt (9849, 2017-10-01)
data\sets.txt (3639, 2017-10-01)
data\sudoku.txt (4899, 2017-10-01)
data\triangle.txt (15150, 2017-10-01)
data\triangles.txt (26383, 2017-10-01)
data\words.txt (16345, 2017-10-01)
project.clj (473, 2017-10-01)
src (0, 2017-10-01)
src\euler (0, 2017-10-01)
src\euler\core.clj (1744, 2017-10-01)
src\euler\english.clj (1254, 2017-10-01)
src\euler\graph.clj (1320, 2017-10-01)
src\euler\matrix.clj (564, 2017-10-01)
src\euler\numeric.clj (2895, 2017-10-01)
src\euler\p001.clj (134, 2017-10-01)
src\euler\p002.clj (134, 2017-10-01)
src\euler\p003.clj (127, 2017-10-01)
src\euler\p004.clj (164, 2017-10-01)
src\euler\p005.clj (107, 2017-10-01)
src\euler\p006.clj (173, 2017-10-01)
src\euler\p007.clj (106, 2017-10-01)
src\euler\p008.clj (1196, 2017-10-01)
src\euler\p009.clj (360, 2017-10-01)
src\euler\p010.clj (136, 2017-10-01)
src\euler\p011.clj (1865, 2017-10-01)
src\euler\p012.clj (146, 2017-10-01)
src\euler\p013.clj (5234, 2017-10-01)
src\euler\p014.clj (366, 2017-10-01)
src\euler\p015.clj (264, 2017-10-01)
... ...

# euler-clojure My solutions to the [Project Euler][1] problems written in the [Clojure][2] programming language. I am doing this for fun and profit. But mostly fun. It is a great way to learn a new programming language and excercise some math muscles (although some of the math involved was new to me). Given that, these are just my solutions to the problems. There may be cleaner, or more idiomattic ways to do this in Clojure (if so, please drop me a line and let me know). I am learning as I go, so some of the early solutions might be a little off. ## Spoiler warning It should go without saying that if you are trying to solve these problems yourself, looking at my solutions may spoil it for you. Feel free to use these solutions if you wish... only cheating yourself, blah, blah. ## Usage Currently this project requires Clojure 1.2. I will update it to 1.3 sometime soon. I use `lein swank` to get a REPL up and running with the right environment setup. To run the solutions: user> (use 'dma.euler) user> (euler) This will run all of the solutions giving the result, whether it was correct and how long it took (with a warning if it was over a minute... gotta keep myself honest :). You can also run just a specific problem by giving the problem number to the `euler` function: user> (euler 42) ## TODO list * Migrate to 1.4 * Figure out why 87 is now running out of memory. * Clean up numeric.clj * Clean up :use clauses to only specify exactly what is being used in each file * Solve the rest of the problems :) ## Problems to migrate from Ruby project I originally started with Project Euler as a way to learn Ruby. I have migrated most of my original solutions over to Clojure. Although in many cases the Clojure solution is very different from how I solved it in Ruby. Here is my migration TODO list. Problems I have solved in Ruby, but not yet in Clojure: * 96 * 111 * 114 * 115 * 116 * 117 * 124 [1]: http://projecteuler.net [2]: http://clojure.org

近期下载者

相关文件


收藏者