Given that x = 7.5, j = – 1.0, n = 1.0, m = 2.0 the value of --x + j == x > n >= m is :
Show answerHide answer
Correct answer: (A) 0
Explanation
Relational operators > and >= have higher precedence than ==, so the expression is (--x + j) == ((x > n) >= m). --x makes x = 6.5, so LHS = 6.5 + (–1.0) = 5.5. RHS: (6.5 > 1.0) = 1, then (1 >= 2.0) = 0. 5.5 == 0 is false, so the value is 0.