GateAI
Programming in C

GATE CSE 2014 Set 3 · Q11

NAT1 markMedium

Time

The minimum number of arithmetic operations required to evaluate the polynomial P(X)=X5+4X3+6X+5P(X) = X^5 + 4 X^3 + 6 X + 5 for a given value of XX, using only one temporary variable is _______.

Your answerNumerical answer

Enter a value to check

Solution

Step-by-step verified solution

Official answer: 7

Programming in C

The polynomial can be factored as:

P(X)=((X2+4)X2+6)X+5P(X) = ((X^2 + 4)X^2 + 6)X + 5

Using a single temporary variable TT, the evaluation proceeds in the following sequence of arithmetic operations:

  1. T=X×XT = X \times X (Multiplication 1: T=X2T = X^2)

  2. T=T+4T = T + 4 (Addition 1: T=X2+4T = X^2 + 4)

  3. T=T×XT = T \times X (Multiplication 2: T=X3+4XT = X^3 + 4X)

  4. T=T×XT = T \times X (Multiplication 3: T=X4+4X2T = X^4 + 4X^2)

  5. T=T+6T = T + 6 (Addition 2: T=X4+4X2+6T = X^4 + 4X^2 + 6)

  6. T=T×XT = T \times X (Multiplication 4: T=X5+4X3+6XT = X^5 + 4X^3 + 6X)

  7. T=T+5T = T + 5 (Addition 3: T=X5+4X3+6X+5T = X^5 + 4X^3 + 6X + 5)

This requires 4 multiplications and 3 additions, giving a total of 7 arithmetic operations.

Try the question first, then check your work.

Think the official key or this write-up is wrong?

Report error or challenge

Examiner trap

The misconception this question tests

This Programming in C previous year question is Q11 of the GATE CSE 2014 Set 3 paper. Find more GATE CSE PYQs on Programming in C in Programming and Data Structures, or browse all GATE CSE PYQs.

Free diagnostic

Where do you stand for GATE?

Take the 20-minute diagnostic: the 3 topics that cost you the most marks, and a rank range. Or sit 5 related Programming in C PYQs now with no account.

One GATE CSE PYQ every morning

An official question by email at 7 AM IST, with a link to its verified solution. Unsubscribe in one click.

Programming in C in GATE CSE

Programming in C has 74 GATE CSE PYQs across 25 papers from 2011 to 2026. 16 of them are 1-mark NAT questions like this one, and GATE CSE 2014 Set 3 has 3.

How GATE tests Programming in C

More from GATE CSE 2014 Set 3

Share this solution

A plain-text card for WhatsApp or Telegram study groups.

GateAI solution cardGATE CSE 2014 Set 3 · Q11 · NAT

The minimum number of arithmetic operations required to evaluate the polynomial P(X) = X5 + 4 X3 + 6 X + 5 for a given value of X, using only one temporary variable is …

Topic-wise GATE CS PYQs with verified steps

Independent practice explanation verified by the GateAI team. GATE is conducted by the IITs; question text follows the official paper.