Suppose there are N male and N female students. They are randomly distributed into k groups.
Is it more probable for a male student to find himself in a group with more guys and for female student to find herself in a group with more girls?
Suppose there are N male and N female students. They are randomly distributed into k groups.
Is it more probable for a male student to find himself in a group with more guys and for female student to find herself in a group with more girls?
The expected number of males in a randomly-chosen group is exactly half the size of the group.
If a group contains at least one male, then the expected number of males will be slightly larger than half the size (and therefore larger than the expected number of females), so the answer is YES.
There is a bit of a difficulty with the phrasing of the question. For one thing, "randomly distributed" may mean that each group contains exactly $\frac{2 N}{k}$ students, or it may mean that each student chooses a group independently (giving groups of different sizes, some of them perhaps empty). My answer applies to either case. Also, it is not clear whether you are asking if it is more probable for a male student to find himself in a group with more guys than to find himself in a group with more girls, or if you are asking if it is more probable for a male student to find himself in a group with more guys than to find himself in a group with at least as many girls as guys. I am assuming the former interpretation, otherwise (supposing the groups are constrained to be of equal size) if $k = N$, then a male student will find himself partnered with another male with probability $\frac{N-1}{2 N} \lt \frac{1}{2}$, and the answer in this case would be NO.
This problem also gives the answer why you are "always" in the longer queue at the supermarket.
If $k=1$ the answer is trivial: All groups are gender balanced. Therefore we shall assume that $k>1$.
Assume Samuel and Samantha were ill the day the groups were originally formed. If the two Sams are assigned to the groups randomly, the result is just as if there had been no illness.
If Sam and Sam are asigned to the same group (which happens with probability $\frac1k$ if the distribution is uniform, with other distributions, your mileage may vary), we see by symmetry that more guys is exactly as probable as more gals for this group.
If Sam is assigned to a different group than Sam (which happens with probability $1-\frac1k>0$ in the uniform case, but we actually need only assume that the probability is $>0$), then three cases are possible:
The group was gender-balanced before with some probability $p$, say (clearly, $p>0$, though the exact value depends on the group size).
Or the group had more male members.
By symmetry, the probabilities for the latter two events are equal, hence are $\frac{1- p}2$ each. Then the probability that the group including Sam has more people of the same gender as Sam is at least $p+\frac{1- p}2=\frac{1+ p}2>\frac12$.
In total, it is more probable to find oneself in a group with more people of ones own gender than with less. This holds both for Sam=Samual and Sam=Samantha.