![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
This is just on the subject of the necessity/unnecessity of brackets...
There is no such a topic. There is only the topic about unnecessary brackets (unnecessarily cluttering the code) which the compiler tries to impose by generating warnings
We know each other's opinions on this topic.
We know each other's opinions on the subject.
It is not my opinion - it is the opinion of hundreds of thousands of programmers (I am not a programmer myself) implemented, in particular, in Visual Studio's approach to the issue. And I trust it
I wonder where the threshold for the number of programmers is when one should hesitate? 5 is not enough. 1,000 is not enough. 10,000 - hesitate. And then finally N - trust. However, when it was (N-1) - I didn't trust it yet.
Include logic rather than the emotional perception of "hundreds of thousands of flies can't be wrong."
Engage logic rather than the emotional perception of "hundreds of thousands of flies can't be wrong".
My logic is simple: brackets don't prioritise, they only change priorities. If there are brackets, the priorities are changed, if there are no brackets, the default priorities apply
If you take the approach that everything is determined by parentheses, then priorities are not needed at all
If there are brackets, the priorities have changed, if not, the default priorities apply
Illogical statement.
An illogical statement.
What is the contradiction?
The presence of brackets does not at all indicate a change in existing priorities.
The presence of parentheses does not at all indicate a change in existing priorities.
So in your code brackets do not mean anything, the statement ... Seems illogical and in case of brackets you have to find out if priorities/order have actually changed, while in my code brackets by themselves mean changed priorities/order (the presence/absence of brackets makes everything clear)
There is no such a topic. There is only the topic about unnecessary brackets(excessively obfuscating code) which the compiler is trying to impose by generating warnings
Have you tried reading the link you gave us? Slava there popularly explains why it is so - because the priority was mixed up in the old MQL4. So now it is important to attract attention. It is even worse that it is only a warning, it would be better if there is an error.