$c_j$ should be clarified to denote the number of students with greater than or equal to $j$ friends and the summation on the right should be corrected to be $\sum\limits_{j=\color{red}{1}}^{99}c_j$
Sort the people in order of number of friends they have, highest to lowest.
Draw a Young Diagram (or Ferrers Diagram) in the following way:
- In column $i$, draw a number of dots in a grid filling spaces from top to bottom equal to the number of friends person $i$ has.
You wind up with something looking like this:
$$\begin{array}{ccccccc}\bullet&\bullet&\bullet&\bullet&\bullet&\bullet&\bullet\\\bullet&\bullet&\bullet\\\bullet&\bullet&\bullet\\\bullet&\bullet\\\bullet\end{array}$$
We may count how many dots there are in this diagram in two different ways
- Add up the amounts in each column individually, and add the results together
- Add up the amounts in each row individually, and add the results together
Since these two methods both correctly count the total number of dots, their expressions must be equal.
Now, recognize that the action of adding column by column corresponds to $\sum a_i$.
Further recognize that row $j$ will have exactly $c_j$ dots in it, and so summing row by row corresponds to $\sum c_j$.
Finally, notice that the bounds on both summations will not prevent any row or column from being counted in the total.