Conditional Probability Examples in Math

Worked examples of Conditional Probability to try before you open each solution, then practice problems with answers.

Worked Examples

Example 1

medium
In a class of 30 students, 18 play soccer, 12 play basketball, and 6 play both. If a student plays soccer, what is the probability they also play basketball?
Show solution

Answer

P(B∣S)=13

First step

1.
We need P(B∣S)=P(B∩S)P(S).

See the full worked solution + why-it-works coaching

SetupKey insightWhy it worksCommon pitfallConnection

Free: full solutions on 3 topics a day. No card.

Every topic, every day: the Family plan

Example 2

hard
A test for a disease is 95% accurate (true positive rate) with a 3% false positive rate. If 1% of the population has the disease, what is the probability a person who tests positive actually has the disease?

Example 3

medium
Of 200 surveyed, 120 own a dog and 80 own a cat; 50 own both. P(cat∣dog)=?

Example 4

medium
Show why P(A∣B)≠P(B∣A) in general by example: P(A)=0.5,P(B)=0.1,P(A∩B)=0.05. Find both.

Example 5

hard
Among 1000 patients, 100 have disease D. A test has 90% sensitivity and 80% specificity. Of those testing positive, how many actually have D?

Example 6

challenge
Monty Hall: 3 doors, 1 prize. You pick door 1. Monty reveals a goat behind door 3. If you switch to door 2, P(win)=?

Example 7

challenge
A pair of dice is rolled until the sum is 7 or 11. Find P(the stopping sum is 11).

Practice Problems

Try each one, then open the solution to compare your method.

Example 1

medium
Two cards are drawn without replacement from a standard deck. Given that the first card is a king, what is the probability the second card is also a king?

Example 2

hard
A jar contains 6 red marbles and 4 blue marbles. Two marbles are drawn without replacement. Given that at least one marble is blue, what is the probability both marbles are blue?

Example 3

easy
A bag has 10 marbles, 4 of which are red. P(red)=?

Example 4

easy
Of 20 students, 12 like math and 5 like both math and art. P(art∣math)=?

Example 5

easy
P(A∩B)=0.2 and P(B)=0.5. Find P(A∣B).

Example 6

easy
A die is rolled. Given the result is even, P(it is 6)=?

Example 7

easy
A card is drawn from 52. Given it is a heart, P(it is the ace)=?

Example 8

easy
P(B)=0.4, P(A∣B)=0.5. Find P(A∩B).

Example 9

easy
In a class, P(passes∣studied)=0.9. If 20 studied, how many are expected to pass?

Example 10

easy
P(A∣B)=P(A∩B)P(B). What must be true of P(B) for this to be defined?

Example 11

medium
A box has 5 red and 3 blue. Two are drawn without replacement. P(2nd red∣1st red)=?

Example 12

medium
60% of emails are spam; 80% of spam contains 'free'. P(spam and ’free’)=?

Example 13

medium
A test is 95% accurate. P(positive∣disease)=0.95, P(disease)=0.02. Find P(disease and positive).

Example 14

medium
Table: of 100 people, 30 smoke; 18 of smokers have cough. P(cough∣smoke)=?

Example 15

medium
Two dice rolled. Given the sum is 7, P(one die shows 3)=?

Example 16

medium
P(A)=0.3, P(B)=0.5, P(A∩B)=0.15. Find P(A∣B) and state if A,B independent.

Example 17

medium
A jar: 7 green, 3 yellow. Draw two without replacement. P(both green)=?

Example 18

medium
In a deck, P(king∣face card)=? (face cards: J, Q, K).

Example 19

medium
P(rain)=0.3, P(traffic∣rain)=0.7, P(traffic∣no rain)=0.2. Find P(traffic).

Example 20

challenge
A test: P(+∣D)=0.9, P(+∣D′)=0.1, P(D)=0.05. Find P(D∣+) (Bayes).

Example 21

challenge
Three urns equally likely. Urn contents: P(red)=0.2,0.5,0.8. A red is drawn. P(urn 3∣red)=?

Example 22

challenge
Family has two children. Given at least one is a boy, P(both boys)=?

Example 23

easy
P(A∩B)=0.12 and P(B)=0.3. Find P(A∣B).

Example 24

easy
A die is rolled. Given the result is odd, what is P(it is 3)?

Example 25

easy
A card is drawn from 52. Given it is a face card (J, Q, K), what is P(queen)?

Example 26

easy
A coin is flipped twice. Given the first flip is heads, what is P(second is heads)?

Example 27

easy
A class has 25 students; 10 play soccer and 4 of those also play tennis. P(tennis∣soccer)=?

Example 28

easy
P(B)=0.5 and P(A∣B)=0.6. Find P(A∩B).

Example 29

medium
Two dice are rolled. Given the sum is 8, what is P(a die shows 5)?

Example 30

medium
A box has 4 red and 6 blue balls. Two are drawn without replacement. Given the first is blue, P(second is blue)=?

Example 31

medium
70% of customers want coffee; among them, 30% also want pastry. P(coffee and pastry)=?

Example 32

medium
A two-way table: 40 students total. 24 took the bus, 16 walked. Among bus riders, 18 ate breakfast. P(breakfast∣bus)=?

Example 33

medium
P(A)=0.6, P(B)=0.5, P(A∩B)=0.3. Are A,B independent? Answer 1 for yes.

Example 34

medium
A bag has 5 red, 3 green, 2 yellow. Two drawn without replacement. P(second is red∣first is green)=?

Example 35

medium
P(snow)=0.2, P(accident∣snow)=0.4, P(accident∣no snow)=0.05. P(accident)=?

Example 36

medium
A family has 3 children. Given the eldest is a girl, P(all three are girls)=? Assume independent and equally likely.

Example 37

hard
P(rare)=0.01, P(+∣rare)=0.99, P(+∣not rare)=0.05. By Bayes' rule, P(rare∣+)=? Round to 3 decimals.

Example 38

hard
Three coins flipped. Given at least two heads, P(all three heads)=?

Example 39

hard
Two dice rolled. Given at least one die shows 6, P(sum is 10)=?

Example 40

hard
Two urns: Urn 1 has 3 red, 1 blue; Urn 2 has 1 red, 3 blue. An urn is chosen at random, then a ball. Given the ball is red, P(Urn 1)=?

Example 41

challenge
A family has 2 children. Given that one of them is a boy born on a Tuesday, P(both are boys)=? (Independent, equally likely days and sexes.)

Example 42

hard
A die is rolled twice. Given the sum is at least 9, find P(first roll is 6).

Example 43

challenge
A family has three children. Given at least one boy, find P(at least two boys). Assume each child independently is a boy with probability 1/2.

Example 44

challenge
A randomly chosen integer from 1 to 1000 is divisible by 5. Find P(also divisible by 6∣divisible by 5).

What to focus on

Core idea: P(A∣B) is the chance of A once you restrict attention to only the cases where B already happened.

Common stuck point: The procedure for conditional probability is the easy part; the trap is dividing by the whole sample space. Asking "Has some information already been revealed that shrinks the set of possible outcomes?" first is what keeps a correct-looking calculation from being attached to the wrong concept.

Ask yourself: Has some information already been revealed that shrinks the set of possible outcomes?

Concept recap

The conditional probability P(A∣B) is the probability of event A occurring given that event B has already occurred.

Conditioning is a search filter. Filter a deck to red cards and 26 remain; hearts are half of what is on screen, so P(heart∣red)=12. Filter to hearts instead and every result is red, so P(red∣heart)=1. Swapping the filter changes the answer.

Read the full lesson on Conditional Probability

Background knowledge

These ideas may be useful before you work through the harder examples.

probabilityindependent events