Probability of a machine with two switches failing A certain type of switch has a probability p of working when it is turned on. Machine A, which has two of these switches, needs both such switches to be switched on to work, and machine B (also with two of the same switch) only needs at least one of them switched on to work.
How can I calculate the probability that each machine will fail to work?

Prob of both switches on A working: $p^2$
Prob of one of switches on B working = prob NOT both of them fail: $1-(1-p)^2$
so $p^2(1-(1-p)^2)$ is the probability both is working
