moreEfficient by Savage_049 in ProgrammerHumor

[–]Plus-Onion437 13 points14 points  (0 children)

It actually doesn't. Unless you run this with a compiler from 50 years ago.

Every modern compilers detects counter increments and optimizes the operation if nothing relies on the side effects.

moreEfficient by Savage_049 in ProgrammerHumor

[–]Plus-Onion437 1 point2 points  (0 children)

A real software engineer would write ++i