Syntax Question for index in a loop

I believe there is something similar to:

1
2
3
4
if (counter++ && value1 < value2)
{
    //do something
}


and I was wondering if anyone knows what it might be? The purpose is to accurately count the number of key-value comparisons regardless of whether the loop itself executes. I know the idea behind it is that the part regarding the counter always resolves true somehow so that it won't really affect the comparison.
Topic archived. No new replies allowed.