Jacobs Interview Question

Calculating the frame