Combinatorics choosing members for a class. The question goes as follows:

We have two classes of students, Class A and Class B and $n$ students to sort into either class. We randomly choose a number $x$ between $1$ and $n-1$ to give us the class size. $x$ is then the size of Class A. From this we pick the students for the class A with each set of students chosen being equally likely. Then the remaining students ($n-x$) make up Class B. Consider a particular student, student $1$. What is the probability of the class containing student $1$ to have a size $m$ for $m$ from $(1.\;.\;.\;n-1)$

This is my working so far. I believe we need to use Baye's conditional formula to work out the probability of the size of the class given that student $1$ is in said class. Hence $$P(\text{size of class}|\text{Student}\; 1 )=\frac{P(\text{Student}\; 1|\text{size of class})\cdot P(\text{size of class})}{P(\text{Student}\; 1)}$$ Now $$P(\text{Student}\; 1|\text{size of class})=\frac{n-1\choose m-1}{n\choose m}$$
And $P(\text{size of class})=\frac{1}{n-1}$. However I'm having trouble seeing where $P(\text{Student}\; 1)$ comes from. Any pointers?
 A: HINT: There are $2^{n-1}-1$ possible classes that contain Student $1$. (Why?) For a given $m$, how many of them have $m$ members?
A: You can clarify things a bit by writing out your events in greater detail. The event "size of class = n" is actually "size of class we observe = n", and the event "Student 1" is actually "Student 1 is in the class we observe". So when you're looking for $P(\text{Student 1})$, what you're looking for is the probability that Student 1 is in the class you're observing, before knowing how large the class is.
There are two ways of thinking about how you calculate this value, and both will take you to the same answer.
First Way
The first way to calculate this probability is as the expected value of $P(\text{Student 1})$ for unknown class size. That is, $$P(\text{Student 1}) = \sum P(\text{Student 1} \mid \text{class size}) \cdot P(\text{class size})$$ where the sum is taken over all possible values of class size.
Second Way
The second way is to recall that what Bayes' Theorem gives you is a probability. Therefore, $P(\text{class size = x} \mid \text{Student 1})$ must sum to $1$ if you sum over all values $x$ of class size. Since the denominator $P(\text{Student 1})$ doesn't depend on class size, we can write \begin{align*}1 = \sum P( \text{class size}\mid \text{Student 1} ) & = \sum \frac{P(\text{Student 1} \mid \text{class size}) \cdot P(\text{class size})}{P(\text{Student 1})} \\
& = \frac{\sum P(\text{Student 1} \mid \text{class size}) \cdot P(\text{class size})}{P(\text{Student 1})}\end{align*} and therefore $$P(\text{Student 1}) = \sum P(\text{Student 1} \mid \text{class size}) \cdot P(\text{class size}).$$
