This could be wrong because of lack of information. I saw the ¨24 cubic centimetres¨ so I assumed that is what you are looking for. If so, you just need to find the length, width and height of each shape. Then multiply them.
I am terribly sorry if this is wrong, but this is all I can come up with because of little information