Skip to content

Comment on Ask HN: A random maths problem we started discussing at work

Comments

I have no answer for you. I mean... the solution seems to be 2121 or 2122 (no, it isn't, see below) determined by brute force, but I don't know why.

But, it's worth noting that if this interests you, Project Euler almost certainly will as well and is worth checking it out if you don't already know about it:

http://projecteuler.net/

EDIT: So if you're wondering why I got a different brute force result from other users, it's because I had a stupid bug. I was looking at the ratio of meeting the criteria to the ratio of not meeting it, not the ratio of meeting it to total.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.