There are $n$ lights in a row. Some of the $n$ lights are on. I can damage any light that is on. If I damage a light, each light directly adjacent to the damaged light will be turned on if it is off, off if it is on. Damaged lights remain unchanged. Prove that I can damage all $n$ lights if and only if the number of lights that are initially on is odd.
Example: off, on, off
I damage the 2nd light
on, (damaged), on
My thoughts are to prove by contradiction, where assume the number of lights turned on is even. But I can't see what follows.
Nice puzzle.
To make the question more clear, it actually means the following:
If an initial status of the lights has an odd number of lights on, then there exists a way (i.e. one specific order) to damage all the lights. Otherwise, there is no way to damage all the lights, in whatever order.
Proof:
We prove by induction on the number of lights in the row.
If there is only $0$ or $1$ light, then everything is clear.
Assume we have proved the result for $< n$ lights.
Now for $n(\geq 2)$ lights in a row, we consider the two cases:
If there are an odd number of lights on, then we may damage (say) the first light on the left which is on. This will break the row into two parts, which then don't interfere with each other from that point on, hence could be viewed as two separate rows of lights.
Now it is easy to see that both parts have either $0$ light or an odd number of lights on. By our induction hypothesis, there is a way to damage both of them.
Similarly, if there are an even number of lights on, then whichever light you damage, there is always one part which has more than $0$ light and an even number of lights on. Again by our induction hypothesis, it is impossible to damage all the lights.