Notice the picture below
so... a cube has all sides equal, so is just a rectangular prism with equal sides
and a rectangular prism is just 6 rectangles stacked up to each other at the edges
now, notice in the graph at the bottom, one of the rectangles with a thickness of 2inches
so... just get the volume of each, and add them up, that's how much metal is needed