Project Euler

Moderator
Posts: 702
Joined: 2002.04
Post: #1
I'm just curious whether anybody here has participated in Project Euler? If you have, have you ever referenced Project Euler when applying for jobs or to schools/colleges/universities/things of that ilk?

I learned of Project Euler in December, and started solving problems a fortnight or so ago to try to achieve Level 1 by the end of the year (I have a... rather low opinion of my mathematical ability Cry)

[Image: sealfin.png]

Mark Bishop
--
Student and freelance OS X & iOS developer
Quote this message in a reply
Moderator
Posts: 1,560
Joined: 2003.10
Post: #2
(Mar 13, 2013 11:10 AM)sealfin Wrote:  If you have, have you ever referenced Project Euler when applying for jobs or to schools/colleges/universities/things of that ilk?

Haven't played with it myself, but I participated in an interview (as an interviewer) at a previous job where a coworker of mine brought up a problem from Project Euler to test our interviewee. Can't hurt to have that skillset under your belt.
Quote this message in a reply
Member
Posts: 34
Joined: 2010.01
Post: #3
I've looked at the website and solved some of the problems for fun. I never registered an account or anything like that though. How do you achieve Level 1? By solving a certain number of problems? (Don't have that much experience with job applying, so not quite applicable question for me).
Quote this message in a reply
Member
Posts: 338
Joined: 2004.07
Post: #4
This looks fun as hell! I immediately registered an account.

Quote: How do you achieve Level 1? By solving a certain number of problems?

Looks like you level up for every 25 problems you solve. Once you solve a problem you can access a thread about it and discuss the solution with other people. It seems like a reeeeally cool little rabbit hole.

Justin Ficarrotta
http://www.justinfic.com
"It is better to be The Man than to work for The Man." - Alexander Seropian
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #5
I'd not heard of it before today, but I did a few this afternoon.

You can friend me with this code:
Code:
41381076451676_84078668b178211e4cb7a50cd421c73a
Quote this message in a reply
Member
Posts: 338
Joined: 2004.07
Post: #6
Here's mine:

Code:
34660844451874_25e3b03bbbb49c27f0b2c946d8232a73

This is bad. This is really, really bad. I'm 10 problems in and my eyes are bleary. I haven't done anything else since the post I made above. I'm trying to make myself stop but I peeked at #11 and I know how to do it. It would just take a little while. I could just not sleep and do it real quick.

O gods, what have I done?

Justin Ficarrotta
http://www.justinfic.com
"It is better to be The Man than to work for The Man." - Alexander Seropian
Quote this message in a reply
Moderator
Posts: 702
Joined: 2002.04
Post: #7
(Mar 14, 2013 01:42 AM)OneSadCookie Wrote:  You can friend me with this code:

(Mar 14, 2013 03:08 AM)JustinFic Wrote:  Here's mine:

Here's mine:

Code:
86013192444836_cbab5ac975cbfe91925b3389af9bd154

(Mar 13, 2013 11:37 PM)JustinFic Wrote:  
(Mar 13, 2013 06:17 PM)Zorg Wrote:  How do you achieve Level 1? By solving a certain number of problems?
Looks like you level up for every 25 problems you solve.

Yeah, you gain a level every twenty-five problems you solve, the maximum level being fifteen; you're also able to gain awards, eg. solving ten consecutive problems gains you the "Decathlete" award, though the only award I've gained thus far is:

Project Euler Wrote:[Image: baby-steps.png]
Baby Steps: Solve three problems

LOL

Mark Bishop
--
Student and freelance OS X & iOS developer
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #8
The first rule of these problems is definitely, get a bignum library, or a language with one built in...
Quote this message in a reply
Member
Posts: 34
Joined: 2010.01
Post: #9
Haha. I'm surprised you guys haven't heard of it:

Here's my code: 97156062452226_f98c8789267e769bdb1749698506fc21

I think I have a source code file where I solved a few problems a while back.. Going to go find it.
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #10
For those of you following along at home, OS X's default Ruby has a horrible bug with the Fixnum->Bignum transition which will give incorrect results for a large range of computations.

So if 19**15 gives you a negative number, this is why:

http://stackoverflow.com/questions/12009...g-answers/

and here's a horrific workaround I found:

Code:
# OS X's ruby has bugs with multiplications which fall into signed ranges of the
# underlying type of Fixnum
# hack around this.

def to_bignum(x)
    # there has to be a better way to do this :|
    0xfffffffffffffffff.coerce(x)[0]
end

def big_pow(a, b)
    a = to_bignum(a)
    r = 1
    b.times do
        r = to_bignum(r) * a
    end
    r
end
Quote this message in a reply
Moderator
Posts: 702
Joined: 2002.04
Post: #11
So, that's Level 1 and this year's target hit Blink LOL

Mark Bishop
--
Student and freelance OS X & iOS developer
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #12
grats Smile
Quote this message in a reply
Moderator
Posts: 702
Joined: 2002.04
Post: #13
I'd assume that everybody here is already aware of this, but on the off chance that somebody is not: Project Euler has been (partially) offline since Sunday (15th June) due to a security breach, and it has been reported by Project Euler staff that it is "highly likely" that all email addresses and passwords have been compromised – according to Project Euler staff passwords were salted and hashed... but the salting function has also been compromised.

Mark Bishop
--
Student and freelance OS X & iOS developer
Quote this message in a reply
Member
Posts: 34
Joined: 2010.01
Post: #14
Well I don't think my password on there is used anywhere else; phewf.
Quote this message in a reply
Post Reply