0
Can someone explain this output for me?
Why does it sort of revert? https://code.sololearn.com/ciXKCOW9GHUP/?ref=app
3 Respostas
+ 3
Compiler starts program execution form right to left. So, a=10
First a++ (post increment) set the a to 10
Second ++a(pre increment) set the value to 12 because previous 'a' is also increment by 1 now it's again incrementing by 1 which makes 'a' incremented by 2
Third now our a is 12 so it print 12
Output,
12 12 10
0
Cool. Thanks👍