3 ms·
The difference is that the article is investigating using a property in the boundary check. The boundary check is evaluated with every iteration. Your example
by mtVessel 7y ago
The difference is that the article is investigating using a property in the boundary check. The boundary check is evaluated with every iteration. Your example is only using it in the initialization expression which, by definition, is evaluated only once. This holds true for virtually any language with a for construct.