You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following anti-pattern is possible but should be discouraged:
for i in array:
...
doSomething(i)
Reasons for discouraging this pattern:
for-in and native for will be off by 1 after loop terminates (this is implementation detail but a fix isn't worth it)
this is illegal in all languages with proper scoping (i.e. perl) and will be illegal in JavaScript in the future (when let keyword is used for loop iterators)
this pattern is discouraged even in languages where it's legal due to ambiguity
The text was updated successfully, but these errors were encountered:
The following anti-pattern is possible but should be discouraged:
Reasons for discouraging this pattern:
let
keyword is used for loop iterators)The text was updated successfully, but these errors were encountered: