Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 633

 
Andrey Sokolov:

right?


You can do this, you can open a folder and select the right tester file - it depends on the task.

 
Artyom Trishkin:

you can open the folder

Alpari Limited MT4\tester\logs

right?

 

Good afternoon!

Guys, I've got a loop. It seems to be simple as pie.

int r=10;

for(int i=r; i<300; i++)

{

Print(i);

}

So, i starts printing from 250 instead of 10.

Why and how can I fight it?

 
Valerius:

Good afternoon!

Guys, I've got a loop. It seems to be simple as pie.

int r=10;

for(int i=r; i<300; i++)

{

Print(i);

}

So, i starts printing from 250 instead of 10.

Why and how can I fight it?

The answer is on the previous page.
 

What it says about skips doesn't tell me anything.

But if we put a condition in this loop, e.g.

if(i==20) Print(i);

it is not satisfied.

 
Valerius:

What it says about skips doesn't tell me anything.

But if you put a condition in this loop, e.g.

if(i==20) Print(i);

it is not satisfied.

What is this panic? An experienced coder gave you a hint but it "does not tell you anything". Then you will have to learn how to ask questions correctly.

 
Valerius:

Good afternoon!

Guys, I've got a loop. It seems to be simple as pie.

int r=10;

for(int i=r; i<300; i++)

{

Print(i);

}

So, i starts printing from 250 instead of 10.

Why and how can I fight it?

Learn to use the debugger and check step by step when it prints what.
 

This is how I check in the debugger and in the tester.

It comes out like this, as I wrote above.

Print is not printed from 10, but from 250...

 
Valerius:

This is how I check in the debugger and in the tester.

It comes out like this, as I wrote above.

Print is not printed from 10, but from 250...

Open the magazine. See last page. And at the same time, print out r too.
 
Valerius:

This is how I check in the debugger and in the tester.

It comes out like this, as I wrote above.

Print is not printed from 10, but from 250...

In the tester and in the debugger step by step are two big differences...

Reason: