Project Euler #213: Flea Circus