Is it more performant to do a pre-increment vs a post-increment in a for loop in java ?
Sample code :
for (int i=0; i<10; i++)
and
for (int i=0; i<10; ++i)
I notice that when i do a pre-increment, the execution time is lesser that when i do the post-increment. Any suggestions on why this might be the case ? thanks.