Code: Select all
print(f "What is the probability of NOT flipping a tail on a single coin?")
P_of_getting_a_tail_on_1_C = 0.50
# This is due to the probability being 1 out of 2 outcomes which is 1/2
P_of_NOT_getting_a_tail_on_1_C = 1 - P_of_getting_a_tail_on_1_C
# The answer is 0.50
percent_P_of_NOT_getting_a_tail_on_1_C = P_of_NOT_getting_a_tail_on_1_C * 100
print(f "The probability of not getting a tail from the flip is {P_of_NOT_getting_a_tail_on_1_C} which is {percent_P_of_NOT_getting_a_tail_on_1_C } %")
All probabilities can be seen as decimal numbers below or equal to 1 so the above is true.Read: The negated probability of an event equals 1 minus the probability of the event.
What is the probability of NOT flipping a tail on a single coin?
\(\neg P(tail) = 1 - P(tail)\)
\(\neg P(tail) = 1 - 0.50 = 0.50\)
\(and\,\,0.50 * 100 = 50 \%\)
