Stefanini Interview Question

<algorithm> Detail below the output of the algorithm above.