Movie theater A has a popcorn machine with a 120-gallon capacity. It sells 7 gallons of popcorn per hour. Movie theater B has a popcorn machine with a 150-gallon capacity. It sells 9 gallons of popcorn per hour. Write and solve an equation to show when the two popcorn machines will have the same amount of popcorn left.

Let's assume t hours have passed since the popcorn machines were filled with popcorn.

The amount of popcorn remaining in Theater A after t hours is given by 120 - 7t.
The amount of popcorn remaining in Theater B after t hours is given by 150 - 9t.

To find when the two popcorn machines will have the same amount of popcorn left, we can set the two expressions equal to each other and solve for t:

120 - 7t = 150 - 9t

Simplifying the equation, we get:

2t = 30

Dividing both sides by 2, we find that:

t = 15

Therefore, the two popcorn machines will have the same amount of popcorn left after 15 hours.