Step-by-step explanation:
a probability (chance) is always the ratio of
desired cases / totally possible cases
so, in our case here, the whole class represents the totally possible cases (as when a student is picked, he or she is picked from the total set of students in this class).
that total is : x + y
now, our desired case is to pick a girl.
that means the desired cases are x.
and so, the probability to pick a girl in this class is
x/(x+y)