1)

What is the output of following set of code ?

int x,y;
x = (y = 10) + 5;


A) y = 10, x = 5

B) y = 15, x = 5

C) x = 15, y = 10

D) x = 10, y = 10

Answer:

Option C

Explanation:

y is assigned 10 and after that its value is added with 5 and then saved in x, so x will be 15.