The probability that a single event A occurs is:

The probability of two consecutive events A and B is:

Let's calculate the probability of event A: getting heads.
Favorable outcome: heads.
Number of favorable outcomes: 1.
Total outcomes: heads, tails.
Number of total outcomes: 2.
So:

Let's calculate the probability of event B: getting heads in the second flip.
Favorable outcome: heads.
Number of favorable outcomes: 1.
Total outcomes: heads, tails.
Number of total outcomes: 2.
So:

Finally, let's find the probability of getting heads twice.

Finding the probability in percentual:

Answer: 1/4 = 25%.