There are two rectangular prisms. The base of the first prism is a
3-in-by-3-in square. The base of the second prism is also a square
whose side is 1 inch shorter. One prism is 10 inches taller than the
other prism. If both prisms have the same volume, what is the
volume of each prism in cubic inches?