George W. answered • 4d

Stats, Math, and Psych Enthusiast--soon to be PhD

If you are randomly selecting a student from the class, let the events A and B be such that A = “Student is a computer science major” and B = “Student is a math major”.

In this case,

P(A) = (# computer science majors)/(Total students in class) = 10/80

P(B) = (# math majors)/(Total students in class) = 20/80

We can further note that the events A and B are disjoint - it’s impossible for a student to be both a computer science major and a math major because no person has a double major.

Therefore, by the addition rule for disjoint events,

P(A or B) = P(A) + P(B) = 10/80 + 20/80 = 30/80 = 0.375

There is a 37.5 % chance that a randomly selected student is a computer science or math major.