It is given that a die is thrown twice
So the total outcome = 62 = 36
Consider P (A) as the probability of getting the number 5 at least once
Consider P (B) as the probability of getting the sum = 8
Sample space of B = {(2, 6), (3, 5), (4, 4), (5, 3), (6, 2)}
P (B) = 5/36
Consider P (A ∩ B) as the probability of getting the number 5 at least once and the sum equal to 8
Sample space of (A ∩ B) = {(3, 5), (5, 3)}
P (A ∩ B) = 2/36 = 1/18
Here the probability that the number 5 have appeared at least once given that the sum is 8