To solve this problem, we need to determine the value of x, which represents the number of students in each third grade class.
Let's break down the information given:
Number of third grade classes: 5
Number of fourth grade classes: 4
Number of fifth grade classes: 4
Number of students in each fourth grade class: 28
Number of students in each fifth grade class: 27
Cost of a hamburger: $2.10
Cost of carrots: $0.50
Cost of a cookie: $0.20
Total cost of one lunch for all the students: $1036
We can set up the equation as follows:
(Number of third grade classes * Number of students in each third grade class * (Cost of a hamburger + Cost of carrots + Cost of a cookie)) + (Number of fourth grade classes * Number of students in each fourth grade class * (Cost of a hamburger + Cost of carrots + Cost of a cookie)) + (Number of fifth grade classes * Number of students in each fifth grade class * (Cost of a hamburger + Cost of carrots + Cost of a cookie)) = Total cost of one lunch for all the students
5x * (2.10 + 0.50 + 0.20) + 4 * 28 * (2.10 + 0.50 + 0.20) + 4 * 27 * (2.10 + 0.50 + 0.20) = 1036
Let's simplify and solve for x:
(5x * 2.80) + (4 * 28 * 2.80) + (4 * 27 * 2.80) = 1036
(14x) + (4 * 28 * 2.80) + (4 * 27 * 2.80) = 1036
14x + 313.6 + 302.4 = 1036
14x + 616 = 1036
To isolate x, we subtract 616 from both sides of the equation:
14x + 616 - 616 = 1036 - 616
14x = 420
To solve for x, we divide both sides of the equation by 14:
x = 420 / 14
x = 30
The value of x is 30.
#### 30
The answer is: 30
Below is a math problem. Provide a detailed, step-by-step solution.

### Problem:
Marla is planning the lunch menu for an elementary school. There are 5 third grade classes with x students each, 4 fourth grade classes with 28 students each, and 4 fifth grade classes with 27 students each. Each student gets a hamburger, which costs $2.10, some carrots, which cost $0.50, and a cookie, which cost $0.20. One lunch for all the students costs 1036.

### Answer:
