The number of students who attend is the independent variable because it does not depend on the amount of food there will be. The amount of food is dependent variable because it depends on the number of students who attend.
The number of students who attend is independent variable and the amount of food is dependent variable.