we know that
The volume of a square prism is equal to

where
A is the area of the base of the prism
H is the height of the prism
The volume of the container is equal to the volume of the larger prism minus the volume of the smaller prism
Step 1
Find the volume of the larger prism

In this case



Step 2
Find the volume of the smaller prism

In this case



Step 3
Find the volume of the container
The volume of the container is equal to the volume of the larger prism minus the volume of the smaller prism
so

Simplify
![V=[B^(2)-b^(2)]*h\ units^(3)](https://img.qammunity.org/2018/formulas/mathematics/high-school/uuy5ogjop3kgsxrrgxi4aidlk7idub9h69.png)
Difference of squares
![V=[B-b]*[B+b]*h\ units^(3)](https://img.qammunity.org/2018/formulas/mathematics/high-school/fcoiifd7yh1rs145m83poy3gdq2kf1z34s.png)
therefore
the answer is
![V=[B-b]*[B+b]*h\ units^(3)](https://img.qammunity.org/2018/formulas/mathematics/high-school/fcoiifd7yh1rs145m83poy3gdq2kf1z34s.png)