There are 49 lamps set in a circle , and a tool that can toggle the stage(on\off) of any set of 5 consecutive lamps.The lamps are all turned off , and the goal is to switch them on. What are the possible no. of times that one would have to use this tool to achieve this?
The options are $25,32,40 $ and $49$
I have seen many problems of this type , but am clueless as to how to approach them. I feel they may use some algorithmic trick , or algorithmic problem solving strategy, like the invariance principle.
Is there a general way to solve problems of this sort? Also, is there an online source/pdf covering problems like this?
Since you are looking for $possible$ number of times, and not necessarily the smallest number of times, one solution is $49$ (which is one of your options).
You begin by using the tool on lamps $1-5$, then on lamps $2-6$, ..., then on lamps $46,47,48,49,1$, then on lamps $47,48,49,1,2$,..., and finally on lamps $49,1,2,3,4$.
This way each lamp is switched 5 times and since $5$ is an odd number, the lamps will be on.