Q.

Consider the following code: int x, y, z;~~~y = 1;~~~z = 5;~~~x = 0 - (++y) + z++;~~~after execution of this, what will be the values of x, y and z?

A. x = 4, y = 1, z = 5.
B. x = 3, y = 2, z = 6.
C. x = -7, y = 1, z = 5.
D. x = 4, y = 2, z = 6.
Answer» B. x = 3, y = 2, z = 6.
660
0
Do you find this helpful?
2

View all MCQs in

Java Programming

Discussion

No comments yet

Related MCQs