Control Flow & Loop Tracing

Answer & solution
Answer: B (no official key was published)
1. The recurrence for p is p₀=1 and pᵢ=pᵢ₋₁x/i. Induction gives pᵢ=xⁱ/i!. The accumulator includes the initial term 1, so it contains exactly y terms, not y+1. Comparing with the Taylor expansion eˣ=1+x+x²/2!+⋯ identifies the limit.
2. Initially p=1 and s=1. On iteration i, p is multiplied by x/i, so it becomes xi/i!, which is added to s. The returned value is the truncated series sum from i=0 to y−1 of xi/i!, approaching ex for fixed x as y increases. Thus B in the mathematical arithmetic model; finite floating-point range/roundoff can limit the actual approximation.