﻿# V3113\. Consider inspecting the loop expression\. It is possible that different variables are used inside initializer and iterator\.

The analyzer detected a 'for' operator whose iterator section contains an increment or decrement operation with a variable that is not the counter of that loop\.

Consider the following expression:

```cpp
for (int i = 0; i != N; ++N)
```

This code is very likely to be incorrect: the 'i' variable should be used instead of 'N' in the increment operation '\+\+N':

```cpp
for (int i = 0; i != N; ++i)
```

Another example:

```cpp
for (int i = N; i >= 0; --N)
```

This code is also incorrect\. The 'i' variable should be decremented instead of 'N':

```cpp
for (int i = N; i >= 0; --i)
```