
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
if (VariableA == VariableB && VariableC == VariableD > VariableX)
{
bool CriteraMet = true;
}
wrong again
supposed to be
As a programmer of some decades experience, believe me ... simple is best. Do *NOT* try to minimise the number of lines of code.
When you come back to code next year or month (or week or day, even), you can forget what you were doing. Having a long chain of A == B || C == D || E == F can make maintenance difficult when you find a bug, or want an enhancement.
So use separate 'if' statements, unless the criteria are extremely related ( like say EMA5 > EMA9 || EMA7 < EMA11 )
As a programmer of some decades experience, believe me ... simple is best. Do *NOT* try to minimise the number of lines of code.
When you come back to code next year or month (or week or day, even), you can forget what you were doing.