The answer is 8 ft.
The base area of rectangular prism is: A = l * w = 56 ft²
The length of the base is longer than the width: l > w
The volume of the prism is: V = l * w * h = 840 ft³
The sum of the length and width of the base is equal to the height of the pyramid: l + w = h
So:
l * w = 56
l * w * h = 840
___
56 * h = 840
h = 840 / 56
h = 15 ft
Now, we know that
l + w = 15 ⇒ w = 15 - l
l * w = 56
___
l * (15 - l) = 56
15l - l² = 56
0 = l² - 15l + 56
Or: l² - 15l + 56 = 0
Let's solve the quadratic function:
l = (-b +/-√(b² - 4ac)/(2a)
= (15 +/-√(-15)² - 4 * 1 * 56))/(2*1)
= (15 +/- √(225 - 224))/2
= (15 +/- √1)/2
= (15 +/-1)/2
l = (15+1)/2 = 16/2 = 8
or
l = (15-1)/2 = 14/2 = 7
If l = 8, then w = 15 - 8 = 7. So, l > w
If l = 7, then w = 15 - 7 = 8. So, l < w
Therefore, l = 8 ft.