GeneralRevealsv1

The hundred doors puzzle leaves perfect squares open

Only perfect squares have an odd number of positive divisors.

Reddit
Output
Doors 1, 4, 9 through 100 remain open
Input
One hundred closed doors toggled on passes numbered 1 through 100
Relationship

What connects the input and output?

Door n is toggled once for every divisor of n. Divisors normally pair, giving an even count, except when a square root pairs with itself.

Sources

1
  1. en.wikipedia.org: The hundred doors puzzle leaves perfect squares openen.wikipedia.orgCC-BY-SA-4.0

Discussion

0

Sign in to join the discussion.