If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

Dependent probability: coins

We're thinking about how the probability of an event can be dependent on another event occuring in this example problem. Created by Sal Khan.

Want to join the conversation?

  • leaf green style avatar for user arafat623
    why do we multiply 5/8 by 0.25? i mean why do we multiply? why cant we add? whats the significance of multiplication? and why do we add the probabilities at last?
    (9 votes)
    Default Khan Academy avatar avatar for user
    • orange juice squid orange style avatar for user Tucker Quering
      Multiplying 2 probabilities together calculates the probability of them both occurring. We multiply 5/8 by 0.25 to determine the probability of drawing a fair coin and then flipping 2 heads. We then went on to multiply 3/8 by 0.36 to determine the probability of drawing an unfair coin and flipping 2 heads.

      Adding 2 probabilities together calculates the probability that either outcome will occur. We added 0.15625 and 0.135 (the outcomes from our multiplication problems above) together because either of those probabilities result in 2 heads being flipped. The problem never specifies what type of coin is drawn, so we add them together to find the total probability of flipping 2 heads.

      Hope this helps!
      (16 votes)
  • blobby green style avatar for user Hamza Osman
    Am I safe to assume that we are replacing the coins after we've taken them out of the bag? Sal didn't take into account that the probability of drawing a fair or unfair coin would change if the first coin wasn't replaced. How would drawing a coin without replacement change the way we approach this question?
    (7 votes)
    Default Khan Academy avatar avatar for user
  • mr pink red style avatar for user XieXieZheZhe
    if events are dependent why didn't sal use the conditional formula
    p(a|b)=p(a∩b)/p(b),and why did he multiplying the possibility togther?
    (5 votes)
    Default Khan Academy avatar avatar for user
  • old spice man green style avatar for user Bitty
    Would you just add up a 3-branch probability tree if you were choosing 2 coins (thus allowing the possibility of both 1 fair and 1 unfair) to flip instead of just 1?
    (4 votes)
    Default Khan Academy avatar avatar for user
    • blobby green style avatar for user campbell.andrew24
      If picking coins were independent events, you could use a 3-branch tree (2 fair, 2 unfair, one of each). Since in this problem the probability of picking your second coin depends on the first coin you picked, you use a 2 branch tree to pick your first coin, and then on each branch is another 2 branch tree.

      This leads to 4 possible outcomes: (Fair, Fair), (Fair, Unfair), (Unfair, Fair), (Unfair, Unfair). The probability of choosing unfair first is 3/8. After an unfair is chosen, there are 5 fairs and two unfairs left in the bag, and so the probability of choosing (Unfair, Fair) is 3/8*5/7 = 15/56. On the other hand, the probability of getting (Fair, Unfair) is p(1st Fair) * p(2nd Unfair | 1st Fair) = 5/8 * 3/7, because after picking a fair coin, the bag has 4 fair and 3 unfair left.
      (1 vote)
  • blobby green style avatar for user lecheconagujas
    I don't know if maybe they mention probability symbols in other video but could anyone tell me what's the symbol for "either A or B but not both"?
    (1 vote)
    Default Khan Academy avatar avatar for user
  • blobby green style avatar for user majidmotamedi
    So, if we have independent events, we add the probabilities and if we have dependent events, we multiply the probabilities?
    (1 vote)
    Default Khan Academy avatar avatar for user
    • male robot hal style avatar for user Oasis Math
      No, but you're close....

      Independent events are two events where the first one doesn't affect the other one, and if you are doing two events in a row you multiply them. Example: If you flip a coin you can get two results, your probability of getting one side is 1/2. But after you flip the coin, that probability doesn't change. The two events are independent. You can multiply them.

      The only time you add them is if you are combining more than one probabilities into a single event. For example, if the probability I pick red is 1/4, and the probability I pick yellow is 2/4, then the probability I pick red OR yellow is 3/4.

      Dependent events are a little harder to calculate. You do multiply them, but the probabilities change as you progress. You should watch this video to start with: https://www.khanacademy.org/math/precalculus/prob-comb/dependent-events-precalc/v/introduction-to-dependent-probability
      (4 votes)
  • leaf green style avatar for user arafat623
    the probability of getting two heads in a row for a fair coin is 0.5*0.5. My question is why do we multiply both the probabilities? why dont we add 0.5 and 0.5?
    (1 vote)
    Default Khan Academy avatar avatar for user
    • mr pink red style avatar for user andrewp18
      The coin flips are independent events. That is, the first flip does not influence what the second flip will be in any way. So we see that there are 4 possibilities:
      HT
      TH
      HH
      TT
      These possibilities could be counted by noting that we have 2 options for the first flip, but each option of the first flip can be associated with one of 2 different possible options for the second flip. Thus our total count of possibilities is 2 • 2 = 4 which we also found by listing them all out above. Remember the probability is desired/total, and we know that there is only 1 desired and 2 • 2 total, so we can express the probability as:
      (1/2)(1/2) = 1/(2 • 2) = 1/4
      I suggest you watch the videos on independent events and multiplying probabilities on KA to gain more intuition. Comment if you have questions!
      (4 votes)
  • starky seedling style avatar for user marvellous.field
    I also got a 0.2889 answer. I see below many others actually got the same answer as me but nobody actually answered why this was wrong or attended to correct it. Anyone has any idea?
    (2 votes)
    Default Khan Academy avatar avatar for user
    • primosaur seed style avatar for user Ian Pulizzotto
      Great question!

      The answer 0.2889, or more precisely 0.28890625 = (0.6*3/8 + 0.5*5/8)^2, is the result of misinterpreting the problem as selecting a coin, flipping it, putting it back, selecting a coin again, and flipping it. Equivalently, this is the result of mistakenly assuming that the two flips are overall independent.

      The flips are not overall independent because the same coin is flipped twice, and if the first flip is heads, this increases the probability that the coin was the type that favors heads, which in turn increases the probability that the second flip of the same coin is heads. This is why the probability that both flips are heads is slightly larger than 0.28890625.

      Have a blessed, wonderful day!
      (2 votes)
  • piceratops ultimate style avatar for user fkahura99
    because, it is another way of finding the probability of dependent events.
    (2 votes)
    Default Khan Academy avatar avatar for user
  • blobby green style avatar for user phani.devatha
    I believe the Fair an Unfair probabilities need to be averaged at the end. Can you please review?
    (2 votes)
    Default Khan Academy avatar avatar for user

Video transcript

You have eight coins in a bag. Three of them are unfair in that they have a 60% chance of coming up heads when flipped. The rest are fair coins. So if three or unfair, the rest are eight coins. When this problem says that they are fair coins, it means that they have a 50/50 chance of coming up either heads or tails. You randomly choose one coin from the bag and flip it two times. What is the percent probability of getting two heads? So this is an interesting question, but if we break it down, essentially with a decision tree, it'll help break it down a little bit better. So let's say that we have a bag, three of them are unfair. So we could even visualize a bag. You don't have to do this all the time. I'll do the fair coins in white. One, two, three, four, five fair coins, and we have three unfair coins. One, two, three. And this whole thing is my bag, right over here. That is my bag of coins. When I take my hand in, if I were to take any of these white coins, there's a 50% chance that it gets heads on any flip. The odds of getting two heads in a row would be 50% times 50% for these white coins. But I don't know I'm going to get a white coin. If I get one of these orange coins, I have a 60% chance of coming up heads. If I have picked one of these orange coins, the probability of getting heads twice is going to be 60% times 60%. So how do I factor in this idea that I don't know if I've picked a white fair coin or an orange unfair coin. We'll assume that the coins actually aren't white and orange. They all look like regular coins. So what I'll do is I'll draw a little bit of a decision tree here. I guess maybe I could call it a probability tree. So there's some probability that I pick a fair coin. And there's some probability that I pick an unfair coin. And so what is the probability that I pick a fair coin? Well, one, two, three, four, five out of the total eight coins are fair, so there is a 5/8 probability. I'll write it here on the branch, actually. So there's a 5/8 chance that I pick a fair coin, and then there is a 3-- one, two, three, out of 8 chance that I pick an unfair coin. So if I were to just tell you, what's the probability of picking a fair coin? You'd say oh, 5/8. What's the probability of an unfair coin? 3/8. And you could convert that to a decimal or a percentage or whatever you'd like. Now, given that I have picked a fair coin, what is the probability that I will get heads twice? So let me write it this way. Now this is just notation right here. So the probability of-- I'll call it heads heads-- so I get two heads in a row, given that I have a fair coin-- it looks like very fancy notation, but it's just like look, if you knew for a fact that coin you had is absolutely fair-- that it has a 50% chance of coming up heads-- what is the probability of getting two heads in a row? Then we can just say, well, that's just going to be 50%, so 50% times 50%, which is equal to 25%. Which is equal to 25%. What is the probability that you picked a fair coin and you got two heads in a row? So given that you have a fair coin, it's a 25% chance that you have two heads in a row. But the probability of picking a fair coin and then given the fair coin getting two heads in a row, will be the 5/8 times the 25%. So this whole branch-- I should maybe draw it this way-- the probability of this whole series of events happening. So starting with you picking the fair coin and then getting two heads in a row will be-- I'll write it this way-- it will be 5/8 times this right over here, times the 0.25. I want to make it very clear. The 0.25 is the probability of getting two heads in a row given that you knew that you got a fair coin. But the probability of this whole series of events happening, you would have to multiply this times the probability that you actually got a fair coin. So another way of thinking about it is this is the probability that you got a fair coin and that you have two heads in a row. Now let's do the same thing for the unfair coin. So the probability-- I'll do that in the same green color-- the probability that I get heads heads given that my coin is unfair. So if you were to somehow know that your coin is unfair, what is the probability of getting two heads in a row? Well in this unfair coin, it has a 60% chance of coming up heads. So it will be equal to 0.6 times 0.6, which is 0.36. If you have an unfair coin-- if you know for a fact that you have an unfair coin, if that is a given-- you have a 36% chance of getting two heads in a row. Now if you want to know the probability of this whole series of events-- the probability that you picked an unfair coin and you get two heads in a row, so the probability of unfair and two heads in a row given that you had that unfair coin-- you would multiply this 3/8 times the 0.36. So this will be equal to 3/8 times 0.36. And so let's get a calculator out and calculate these. So if I take 5 divided by 8 times 0.25, I get 0.15625. So this is equal to 0.15625. And then if I do the other part, so if I have 3 divided by 8 times 0.36, that gives me 0.135. So this is 0.135. So if someone were to ask you, what's the probability of picking the fair coin and then getting two heads in a row with that fair coin, you would get this number. If someone were to say, what's the probability of you picked the unfair coin and then get two heads in a row with that unfair coin, you would get this number. Now, if someone were to say, either way, what's the probability of getting two heads in a row? Because that's what they're asking us here. What is the probability of getting two heads? So we could get it through this method-- by chance, picking the fair coin-- or through this method-- by chance, picking the unfair coin. So since we can do it either way, we can sum up the probabilities. Either of these events meet our constraints. So we can just add these two things up. So let's do that. So we can add 0.135 plus 0.15625 gives us 0.29125. So point 0.29125, that's when we add 0.15625 plus 0.135 will equal this. And if we want to write it as a percentage, you essentially just multiply this times 100 and add the percentage sign there. So this is equal to 29.125%. Or if we were to round to the nearest hundredths, then this would be the exact number, or we could say it's approximately 29.13%, depending on how much we need to round it. So we have a little less than a 1/3 chance of this happening. And the reason why-- if everything in the bag was a fair coin, there'd be a 25% chance of this happening because you just say, OK any of these, they're all the same. Flip it twice, 25% chance. Our chance is a little bit higher because there's some probability-- there's a 3/8 chance-- that we pick a coin that has a higher than even chance of coming up heads.