English, asked by kingtaehyung190, 1 month ago

What will be the result stored in x after evaluating the following expression ? int x=4; x+=(x++)+(++x)+x;​

Answers

Answered by komalkuver2590
10

Explanation:

x+=(x++)+(++x)+x; // (x+=) is a short hand operator which means x=x+ and (x++) is a post fix operator which will use the old value of x first and then change the value internally and at the next time the variable will be used it will use the new value

x=4+4+6+6;

x=20;

hope it helps if not then sorryyyyyyyyy

Similar questions