Biography has not been added
- Pre-increment or post-increment in C/C++
This is funny. I had a SW interview and the interviewer asked me the same question. I replied with the same answer as above. I was offered the job but I took another. However, for those wondering, variable a is post-incremented over b's possible pre-increment. This is because post-inc has a higher priority over pre-inc. So the equation is read in the compiler as int c = a++ + b; It compiles. Anyone who does write code like this should be tried and convicted, IMO (joking).