The equation relating this should be linear since the increase in amount earned is constant throughout which is $24 per hour. The equation is in the form:
y = mx + b
where,
y = earning
m = slope or earning per hour = $24
x = total number of hours
b = y intercept or initial earning upon visit = $45
Hence,
y = 24x + 45
Since we are working at two separate work sites, therefore each site we must earn 810/2 = 405
So when y = 405:
405 = 24x + 45
x = 15 hours
So you must work 15 hours at each site, 30 in total.