Probability that a device turns off in n seconds At zero time a device is on, and can be turned on or off at any time.  Let $p_1, p_2, \dots$ the probabilities that the device is off at times $1, 2, \dots$.
What is the probability that the device will be turned off for the first time at time $n$?
EDIT:
I think that it can be solved just by:
$$(1-p_1)\times(1-p_2)\times \dots \times p_n$$
But I am not sure how to arrive this conclusion, as it seems to be backed on independent events, but I cannot be sure about the independence here.

The question concerns a sample space $\Omega$ of sequences of observations of the light made at times $1, 2, 3, \ldots.$ For it to be answerable, we have to suppose that the switch can be flipped no more than once in any interval $(n-1,n]$ (for otherwise the observations do not determine when the switch is flipped).
$\Omega$ therefore can be identified with the set of all binary sequences
$$\Omega = \{\omega\mid \omega:\mathbb{N}\to \{0,1\}\}$$
where $\omega(0)=1$ indicates the light is on at time $0$ and generally at any time $n,$ $\omega(n)=1$ if and only if the light is on at time $n.$
Let $\mathcal{P}_i = \{\omega\mid \omega(i)=0\}$ be the set where the light is off at time $i.$  The problem supposes every $\mathcal{P}_i$ is an event for $i=0,1,2,\ldots$ and the associated probabilities of these events are
$$\Pr(\mathcal{P}_i)=p_i.$$
Any answer therefore boils down to representing the set
$$\mathcal{E}_n = \text{The light was first turned off in the interval }(n-1,n]$$
in terms of the events $\mathcal{P}_i.$
We can try to figure this out recursively.  Begin with $n=1:$ $\mathcal{E}_1$ is the event the light is not on at time $1.$  It is identical to $\mathcal{P}_1,$
$$\mathcal{E}_1 = \mathcal{P}_1.$$
When $n=2,$ $\mathcal{E}_2$ is the event "the light is not on at time $2$ but the light was still on at time $1.$"  In set notation, using overbars to denote complements (with respect to $\Omega$),
$$\mathcal{E}_2 = \mathcal{P}_2\cap \bar{\mathcal{P}_1}.$$
It consists of all sequences of the form $110\ldots\,.$
Because it is difficult to see how the chance of this intersection is determined by any of the specified probabilities $p_i,$ let's look for a counterexample.  Evidently, we can focus on the first three times $0,1,2.$
Consider, then, the family of probability functions $\mathbb{P}_\alpha$ given by this table:
$$\begin{array}{}
\omega & \mathbb{P}_\alpha \\
\hline 111\ldots & \alpha(1-p_1)\\
110\ldots  & (1-\alpha)(1-p_1)\\
101\ldots  & p_1 - p_2 + (1-\alpha)(1-p_1)\\
100\ldots  &  p_2 - (1-\alpha)(1-p_1)
\end{array}$$
The left hand column indicates the four events corresponding to the state of the light at times $0,1,$ and $2$ while the right hand column gives their probabilities.
For this to be a valid probability function, none of the chances can be negative.  This forces $\alpha$ to lie between $0$ and $1$  (to make the first two chances non-negative) and
$$\frac{p_2-p_1}{1-p_1}\le \alpha \le \frac{p_2}{1-p_1}$$
(to make the last two chances non-negative).  For instance, when $p_1=p_2=1/2,$ we must have $0\le \alpha \le 1.$ This demonstrates such probability families exist.
Now since $\mathcal{P}_1 = \{100\ldots, 101\ldots\}$ and $\mathcal{P}_2 = \{100\ldots, 110\ldots\},$ the axioms of probability give
$$\mathbb{P}_\alpha(\mathcal{P}_1) = \mathbb{P}_\alpha(100\ldots) + \mathbb{P}_\alpha(101\ldots) = p_1$$
and
$$\mathbb{P}_\alpha(\mathcal{P}_2) = \mathbb{P}_\alpha(100\ldots) + \mathbb{P}_\alpha(110\ldots) = p_2,$$
showing that these probability functions satisfy all the requirements of the problem.  However,
$$\mathbb{P}_\alpha(\mathcal{E}_2) = \mathbb{P}_\alpha(\mathcal{P}_2 \cap \bar{\mathcal{P}_1}) = \mathbb{P}_\alpha(110\ldots) = (1-\alpha)(1-p_1).$$
This looks like it can vary with $\alpha.$  Indeed, taking the example $p_1=p_2=1/2,$ these probabilities are
$$(1-\alpha)(1-1/2) = (1-\alpha)/2,$$
which (as we saw above) can be any value from $(1-0)/2=1/2$ down to $(1-1)/2=0.$
This proves the question does not generally have a unique answer.  In fact, the restrictions on $\alpha$ only imply
$$p_2 - p_1 \le \Pr(\mathcal{E}_2) \le p_2.$$
Similar inequalities must apply to the chances of all the other events $\mathcal{E}_3,$ $\mathcal{E}_4,$ etc.
