Yesterday, Esperanza worked for 6 hours and earned $120. Today, Esperanza worked 8 hours and earned $156. Write the equation of the linear function that models the relationship between the number of hours Esperanza works and the amount of money she earns. Enter your answer in y=mx+b form.

Let x represent the number of hours Esperanza works.

Let y represent the amount of money she earns.

The given information states that when Esperanza worked 6 hours, she earned $120. This can be written as the point (6, 120).
Similarly, when Esperanza worked 8 hours, she earned $156. This can be written as the point (8, 156).

We can now find the slope of the linear function by using the formula:

slope (m) = (change in y) / (change in x)

m = (156 - 120) / (8 - 6)
m = 36/2
m = 18

Now, we can use the slope-intercept form of a linear equation:

y = mx + b

Plugging in the values of one of the points, say (6, 120), we can solve the equation for b:

120 = 18(6) + b
120 = 108 + b
b = 120 - 108
b = 12

Therefore, the equation of the linear function is:

y = 18x + 12