My question relates to performance comparison (numeric estimates) pertinent to the following sample cases implementing for-loop in C# 4.0 and/or C# 5.0 in 4 different manners:
for (int i=0; i<10000; i++;){string _s="a";}
for (int i=0; i<10000; ++i;){string _s="a";}
for (int i=10000; i>0; i--;){string _s="a";}
for (int i=10000; i>; --i;){string _s="a";}
Question: Which of the following implementations will provide better performance (execution time) in generic for-loop implemented in C# 4.0 or C# 5.0?
Note 1: string _s="a"; is just a sample operation, potentially could be omitted for testing purpose.
Note 2: so far, as per discussion on (Is there a performance difference between i++ and ++i in C?) it seems like ++i runs faster than I++ in C++.