|| means OR
&& means AND
if (OrderSymbol() == Symbol() && OrderMagicNumber() == OrderId2)
means both the symbol and the magic number must match
if (OrderSymbol() == Symbol() || OrderMagicNumber() == OrderId2)
means either the symbol or the magic number must match
Thank you, perfect answer. Furthermore, what is != ?
if (OrderType() != OP_SELL || OrderSymbol() != Symbol())

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
Sorry basic question I know but wondered what is the difference between using || or &&? Example for each would be: