Using C# (or VB.NET) which loop (for loop or do/while loop) should be used when a counter is required?
Does it make a difference if the loop should only iterate a se
Personally I would go with the for loop.
It is better to read, more commonly used and very optimized.
for (int iLoop = 0; iLoop < int.MaxValue && !Criteria; iLoop++) { // Do Work }
Edit: int.MaxValue && !Criteria <- a definietely better approach than my initial one ;)