The riddle of the 100 bulbs and of 100 frogs It is an ingenious and fun rhouting, not only because it stimulates our reasoning, but also because its solution teaches us one mathematical truth!
The situation is this: there are 100 bulbs all in line, initially off, and 100 frogs that light and turn them off jumping over it. Every time one Rana jumps on one turning light this yes turns on, and vice versa. The frogs, however, jump on the bulbs with a precise logic: both the bulbs and the frogs are numbered from 1 to 100 and each frog only jumps on the bulbs that are associated with a multiple number of their number.
How many bulbs remain on After the 100-Esima Rana did its job? Let’s try to understand it together.
The riddle of the 100 frogs and 100 bulbs: which ones remain on?

We speak from first frog. The number assigned to you will be 1 and therefore, since any integer is divisible by 1, all numbers from 2 to 100 are its multiples! For this, the first frog will skip all the bulbs, one at a time, LIBLYING THEM ALL.
There second frogon the other hand, will only skip on equal bulbsthat is, the multiple ones of 2. In short, it will skip two bulbs at a time, and since frog number 1 had turned on all the bulbs, the second frog will turn off All those on which he will find himself jumping. Start from the second, turning it off, then jumps on the fourth and so on, turning off all the light bulbs.
There third frog He manages to jump Three bulbs at a time (the multiples of 3!) And jump in number 3, number 6, 9 and so on. The fourth frog jumps 4 bulbs at a time, the fifth frog 5 bulbs at a time, and so on up to the hundredth frog that jumps directly on the number 100 light bulb.

But while for the first and second frog it was easy to establish which bulbs they would have turned on and which they would have turned off – the first ignited them all, while the second turned off the same – for the remaining frogs the situation becomes a little more complex!
Let’s think for example about the third frog. When he skips on the third light the will turn off, Because he had been lit by the first frog, while the second frog did not touch it being the 3 odd. But when the third frog arrives on the Sixth light bulb – since 6 is multiple of 3 – the will turn on! This is because the sixth light bulb, unlike the third, has already been touched by both the first and the second frog, which then turned it on and then off, and then arrives at the third frog which, in fact, turns it on.
In short … what a confusion. How do we answer the question:
After all the frogs have skipped, which light bulbs will be lit?
To try to give an answer, let’s start from a simplified version of the indovinel
The riddle of frogs and lamps: what happens if they are only 6?
Let’s imagine that the bulbs And the frogs are not 100, but only 6. In this case we just need to think about 1 to 6 numbers and which are their partitions:
- 1 is multiple of only 1, so it will be lit from the first frog and will remain on;
- 2 is multiple of 1 and 2 and therefore it will be pressed twice, that is, on and off, so it will remain off;
- The same thing about the 2nd applies to 3 which, being first, is divided only by 1 and itself and therefore will remain off;
- 4 is multiple of three numbers: 1, 2 and 4and therefore will find himself on;
- 5Like this like 2 and 3it is first and therefore for the same reason it will remain worn out;
- Thus we arrive at 6that being multiple Of four numbers – 1, 2, 3 and 6 – It will be pressed 4 times ending worn out.

In the end, after the passage of the sixth frog, the bulbs that remained on are only number 1 and number 4: what do they have different from the others? On the light bulb 1 only the first frog jumps, while in number 4 3 frogs jump (1, 2 and 4). In both cases it is an odd number of frogs, in all the other cases the number of frogs that jump on the bulbs is equal: two for the bulbs number 2, 3 and 5, while on lightning number 6 they jump four frogs. On the other hand, if initially a light bulb is off, every time they jump over 2 frogs it will be first on and then off, and to turn it on again it should above another frog. Consequentially, To make a light bulb stay on, it is necessary that they jump over an odd number of frogs.
And this is a huge clue! If the bulb remains on when they jump on it an odd number of frogs, it means that The bulbs that have an odd number of dividers remain on! But how do we understand which numbers between 1 and 100 have an odd number of dividers? Is there a general rule?
The solution to the abundance of the 100 frogs and 100 bulbs and the perfect square rule
Well … yes! There is one general rule, a Mathematical law!
To understand it, we start from the example of the reduced indovinel of the 6 bulbs. The only two who remained on were the 1 and 4. What do they have in common? They are the only perfect squares between 1 and 6! And this could be the reading key we needed.
Thanks to the indovinel with only 6 bulbs, we came to understand that to stay on, a light bulb needed to be “skipped” an odd number of times, and therefore to be combined with a number from 1 to 100 that had a odd number of dividers. Is it possible that all the perfect squares – that is, those numbers obtained from an integer multiplied by himself – to have an odd number of dividers?
Let’s try to think about it with some examples. Any number – for example the 15 – can be written as multiplication between two different numbers – 15 in fact it is 3 × 5. And in the case of prime numbers, that is, those whole numbers who have only two dividers, that is 1 and themselves, such as 5? Well, we have already answered the sentence: 5 can be written as 5 × 1.
In short, for any natural number one can be found couple Of numbers natural that, multiplying to each other, give that number as a result. In the case of the prime numbers, this couple is only one and there are only 2 dividers, while in the case of larger numbers, more couples can be found and our number will have as many dividers as much couples! To understand each other, let’s take an example: the number 24 It can be written as 1 × 24, 2 × 12, 3 × 8, 4× 6 And in fact he has 8 dividers: 1, 2, 3, 4, 6, 12, 24.
But if we consider A perfect square, One of these couples will contain a single number! Let’s take the number 16 for example, that is 4 to the second. It can be written as 1 × 16, 2 × 8, 4 × 4. This means that the third multiples pair does not provide two multiples, but only one! That is, the 4.

Basically the numbers that have one odd quantities Of dividers they are only the Perfect squareslike 4 and 16, so the solution of the indovinel is that:
In the end, all the bulbs corresponding to square numbers between 1 and 100 will be lit, namely the number 1, 4, 9, 16, 25, 36, 49, 64, 81 and 100. All other bulbs will be off.