Which combination of the integer variables x, y and z makes the variable a get…

GATE · 2008 · CS

Which combination of the integer variables x, y and z makes the variable a get the value 4 in the following expression?
a = ( x > y ) ? (( x > z ) ? x : z) : (( y > z ) ? y : z )

  1. A.

    x = 3, y = 4, z = 2

  2. B.

    x = 6, y = 5, z = 3

  3. C.

    x = 6, y = 3, z = 5

  4. D.

    x = 5, y = 4, z = 5

Attempted by 1035 students.

Sign up free to check your answer

Sign up free

Explore the full course: Gate Guidance By Sanchit Sir

Loading lesson…