Wednesday, September 2, 2015

Code Golf progress.

After my last post, I noticed a few things. One, the process I am planning to engage in seems to be generally called "Code Golf". Second, a number of the problems I gave before were actually not even the best solutions I had. Third, "Character count" isn't a great measure either, so I will be using the most accurate and universal measure I can think of for now, which is size in memory of the files. Now that I have decided that I will be doing a code golf challenge with Project Euler subject to the one-problem-per-language constraint, I have gone through and chosen my most efficient solutions, which gave the following results:
ProblemFileBytes
2 e2.hs 237
3 e3.cat 181
4 e4.f 156
7 e7.rkt 267
9 e9.fs 449
10 e10.sml 762
11 e11.php 2252
12 e12.go 589
13 e13.lisp 5135
14 e14.js 272
ProblemFileBytes
16 e16.py 76
17 e17.elm 1667
18 e18.scala 798
19 e19.pl 542
20 e20.e 393
21 e21.sq 578
22 e22.d 380
23 e23.ceylon 1061
24 e24.j 14
26 e26.es 480
Total20 Files16289


ProblemFileBytes
2 eg2.hs 114
3 eg3.cat 162
4 e4.f 156
7 eg7.rkt 182
9 eg9.fs 333
10 eg10.sml 318
11 e11.php 2252
12 e12.go 589
13 e13.lisp 5135
14 e14.js 272
ProblemFileBytes
16 e16.py 76
17 e17.elm 1667
18 e18.scala 798
19 e19.pl 542
20 e20.e 393
21 e21.sq 578
22 e22.d 380
23 e23.ceylon 1061
24 e24.j 14
26 e26.es 480
Total20 Files15502
The first table is where I was after just choosing short files. The second table is where I now am after starting to minify some of my solutions (the minified solutions are named "eg", for "euler golf"). I will hopefully finish minifying the solutions in this chart soon.

No comments:

Post a Comment