You can get the answer by dividing the number of students by the number of eggs in a carton, so 314 divided by 12.
314 divided by 12 is 26 and 1.66...
Since every student needs an egg, you need to round up to 27.
If each student gets one egg, the school will need 27 cartons of eggs.