Any two pupils in the school are either friends or not, the friendship is mutual. For each integer 1 ≤ L ≤ 111 there is a school pupil having exactly L friends in the school.
Given that there is no triple of school pupils such that any two of them are friends, find the minimal possible number of pupils in this school.
The answer is $ 111 + (111+1)/2 = 167 $. There are two parts in the answer, firstly we must show that we can achieve our goal with 167 people. Secondly we need to show that we cannot do it with less. For the second, assume that we have a graph with the desired properties and we begin drawing it by first drawing one of the people with 111 friends, then one with 110 (if not already there) and so on. We start with 112 people where the first is a friend of all the others and there is no friendship between the others. You have a person with 111 friends and (a lot of) people with one friend. At the second step you must add at least one person and all his friendships. Other than the the persons with 111 and 110 friends, everybody else on the graph has at most two friends. With this reasoning we see that until $111+1/2$ we are forced to add an extra person to our graph. This shows that we cannot have a graph with less than $ 111 + (111+1)/2 = 167 $ people.
As for he first part it is explained in the comments.