Page 1 of 1

Project Euler

Posted: 2009.05.26 (07:28)
by scythe
http://projecteuler.net/
Anyone else here do these? I've tried a few, mostly the ones I think I can implement quickly. Here's (spoilers!) my take on problem 72, in lua.

Re: Project Euler

Posted: 2009.05.26 (09:24)
by Spawn of Yanni
I've always wanted to try learning programming so I could take a shot at this, because it sounds mad interesting.

Re: Project Euler

Posted: 2009.05.26 (16:12)
by t̷s͢uk̕a͡t͜ư
Goddamnit, scythe. Now I have to do all of these. Thanks a friggin' ton. Ugh.

Meanwhile, my solution (in Python) for #72 before looking at yours:
http://pastebin.ca/1435100

Re: Project Euler

Posted: 2009.05.26 (21:31)
by scythe
Tsukatu wrote:Goddamnit, scythe. Now I have to do all of these. Thanks a friggin' ton. Ugh.
On the plus side, it's a great way to learn the math library.
Meanwhile, my solution (in Python) for #72 before looking at yours:
http://pastebin.ca/1435100
Do you need to sort the factors? It seems like they'd be in order simply because of the way you sorted them.

Re: Project Euler

Posted: 2009.05.26 (22:06)
by t̷s͢uk̕a͡t͜ư
scythe wrote:
Meanwhile, my solution (in Python) for #72 before looking at yours:
http://pastebin.ca/1435100
Do you need to sort the factors? It seems like they'd be in order simply because of the way you sorted them.
Oh. Yeah, probably not. Just making sure it looked clean during debugging.
I mean, I also didn't need all the wacky length checking for num and den because I knew I'd be feeding it numbers between zero and one only, but meh.

Re: Project Euler

Posted: 2009.05.27 (00:35)
by Exüberance
Doing a bunch of these now using mostly C, but using Scheme where I use integers bigger than 2^31 -1. I suppose I could always use my bigint functions, but meh. With scheme I can just type it in and go. Don't have to save, compile, scream in terror at segfault, fix, recompile, and run. Might end up trying to figure out how to make Maple do something usefull for some brute-force algorithms with really big numbers.

Yeah, I just got nerd sniped. <_<