Computer Science, asked by andersonjerin5074, 16 hours ago

Predict the output if int a=6,b=5;a+=a++%b++*a+b++*--b..Do this using postfix and prefix method of java....Fast I will mark you as brainliest!!!!!!​

Answers

Answered by belamkarsavita
1

Answer:

a = 49

WORKING

a += a++ % b++ *a + b++* --b

=> a = a + (a++ % b++ *a + b++* --b)

=> a = 6 + (6 % 5 * 7 + 6 * 6)

// % and * will be applied first due to higher precedence

=> a = 6 + (7 + 36)

=> a = 49

Explanation:

hope you understand

Similar questions