Which one of the following options is correct for the given data in the table?…

2025

Which one of the following options is correct for the given data in the table?

\(\begin{array}{|c|c|c|c|c|} \hline \text{Iteration (i)} & \text{0} & \text{1} & \text{2} & \text{3} \\ \hline \text{Input (I)} & \text{20} & \text{-4} & \text{10} & \text{15} \\ \hline \text{Output (X)} & \text{20} & \text{16} & \text{26} & \text{41} \\ \hline \text{Output (Y)} & \text{20} & \text{-80} & \text{-800} & \text{-12000} \\ \hline \end{array}\)

  1. A.

    \(𝑋(𝑖) = 𝑋(𝑖 − 1) + 𝐼(𝑖); 𝑌(𝑖) = 𝑌(𝑖 − 1)𝐼(𝑖); 𝑖 > 0\)

  2. B.

    \(𝑋(𝑖) = 𝑋(𝑖 − 1)𝐼(𝑖); 𝑌(𝑖) = 𝑌(𝑖 − 1) + 𝐼(𝑖); 𝑖 > 0\)

  3. C.

    \(𝑋(𝑖) = 𝑋(𝑖 − 1)𝐼(𝑖); 𝑌(𝑖) = 𝑌(𝑖 − 1)𝐼(𝑖); 𝑖 > 0\)

  4. D.

    \(𝑋(𝑖) = 𝑋(𝑖 − 1) + 𝐼(𝑖); 𝑌(𝑖) = 𝑌(𝑖 − 1)𝐼(𝑖 − 1); 𝑖 > 0\)

Attempted by 14 students.

Show answer & explanation

Correct answer: A

Solution overview: find the recurrences that reproduce the table of values.

Determine how each output changes from one iteration to the next:

  • X recurrence: X(i) = X(i-1) + I(i)

    1. i = 1: X1 = 20 + (-4) = 16

    2. i = 2: X2 = 16 + 10 = 26

    3. i = 3: X3 = 26 + 15 = 41

  • Y recurrence: Y(i) = Y(i-1) × I(i)

    1. i = 1: Y1 = 20 × (-4) = -80

    2. i = 2: Y2 = -80 × 10 = -800

    3. i = 3: Y3 = -800 × 15 = -12000

Conclusion: The recurrences that match every row of the table are X(i) = X(i-1) + I(i) and Y(i) = Y(i-1) × I(i) for i > 0.

A video solution is available for this question — log in and enroll to watch it.

Explore the full course: Gate Guidance By Sanchit Sir