Solving Project Euler problems
bentilly.blogspot.com
bentilly.blogspot.com
Haskell is actually very good for solving these types of problems. It supports infinite lists and lazy evaluation which help quite a bit.
I find that the best thing about Project Euler is being able to look at how other people have solved the problems - a great way to improve your own code.
If your programming is bad, (hypothetically) you will likely get people to give you good pointers so that you are better next time.
Either way, I see no reason not to, and the fact you are using Arc just increases the importance of helping people to follow along behind you.
It is a losing battle to be sure, but they put a lot of work into it and I prefer it when people respect their request to not facilitate cheating.
I always hated it when teachers would hold on to the solutions to the exercises in the textbook.
On the other hand, people who want to learn Arc might be very greatful to have a good set of code out there.
Some companies in the financial industry use PE problems for interviews. People memorize brainteasers for these interviews, so I imagine people might also want to memorize PE solutions.
And yes, getting pointers on my Arc code would be helpful. So maybe I'll put everything up on github.
That being that people who want to cheat have any number of ways of doing it from finding someone else who posted it publicly, to asking privately, to (in the extreme case) actually paying someone to figure out the answer and give it to them.
And, as I mentioned in a previous post, the people who do not want to cheat, won't. They won't do those searches. If they stumble over it and know what it is they won't read it. If they stumble over it and read it before they know what it is, they will almost certainly forget the details quickly.
So by posting your Arc code publicly, you would neither (significantly) help someone wanting to cheat nor hurt someone not wanting to cheat. But you will help people who want to learn Arc.
No, I'm joking. If that was the only issue, I'd just post them. Somewhere on the Project Euler site -- I can't find it now -- they ask for the solutions not to be posted anywhere. That's my main hangup at this point.
Edit: this one http://projecteuler.net/index.php?section=problems&id=13
I just used a big integer library, calculated the answer, and then took the first 10 digits. That should work out fine in any reasonable general case that you're likely to be thinking of.
There are also a number of problems where it is possible to narrow down the answer fairly easily, then submit a limited number of guesses until you get the right answer without having really shown that it is right.
But they try to limit how easy that is to do.
To some degree, they need to rely on the users to care enough not to "cheat." There is no way to completely avoid people doing things like this.
So when I saw Project Euler I dusted off the problem, and tried to set up a variant that was about the right level of difficulty for a Project Euler problem. :-)