To solve this problem you must apply the proccedure shown below:
1. You have that the total area is obtained by applying the formula for calculate the area of a rectangle and multiply it by the four walls:

2. You know that each gallon of paint covers 100 ft², therefore, you can calculate the amount of gallons needed (which you can call
), if you divide the total area of the walls by the area covered by each gallon:

The answer is: 12 gallons.