Just increment a counter variable (standard coding practice).
int MyCount = 0; for( int i = 1; i <= 10; i++ ) { if( i > num ) { MyCount++; Print( "i: ", i, "; Count: ", MyCount ); } }
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I am currently experimenting conditional loops and came across a problem which I need some help solving it. Please see below my codes.
Does MQL4 has a built in function called COUNT ? So I can do something like count(i), which returns the amount of integers that passes the condition.