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
Thank you! I'm going to try those brackets now!
But you have to check all the options you offer. Otherwise you might make a mistake.
To keep warnings from cluttering up your eyes, use {}: {}
That's like scratching the back of your head with a heel :) Why four extra operations and a superfluous line? Because the original version looked like this:
if (A || B || C || D) Action();
And it's especially amusing that the topicstarter chose your variant out of all offered ))
And it's especially amusing that the topicstarter chose your variant out of all offered ))It's like scratching the back of my head with a heel :) Why 4 extra operations and an extra line? After all, the original version looked like this:
I tested all the proposed options, and it turned out that the fastest is this one: if (A || B || C || D) Action();
To reduce the time, I made some conditions, which are needed very rarely, but in another block, and even added one more, but without bool's, which would add time. I continue to dig through everything possible, looking for justified simplifications, so far on demo works stable and without errors. The thread is open, I will surely share something interesting or unclear. Thank you all!
I tested all the suggested variants, and it turns out that the fastest is this one: if (A || B || C || D) Action();
I wonder how it could be faster than this: if (A) Action(); else if (B) Action(); else if (C) Action(); else if (D) Action();
I wonder how it could be faster than this: if (A) Action(); else if (B) Action(); else if (C) Action(); else if (D) Action();
Sorry, Alexey, just got home! This variant is not suitable, because, as I explained above, Acron(); is not just an execution function, but contains several more conditions, common to the previous ones, but different in direction, and, accordingly, in different order of executing the necessary action functions. As you understand, I could not make the code heavier with this variant. And in principle I agree with you that your version could be faster, if Action(); was just a call of one function, nothing more. Thank you very much for help in my search of optimal solutions! Good night to you!
The result, as you'd expect, is of the "The shampoo got even more anti-dandruffy!!!" variety. :)))
If you associate dandruff in your hair with bugs in the code, then of course you should expect, hope, achieve, look for interesting solutions, but not stampede!
And you call this process (9 pages long) "finding interesting solutions"? :)))
On the 1st page - it was a help on "help", and after the 2nd page there was an interest - "what's the fastest way". BUT the answer to this question assumes to contain figures (I already did not mention "purity of experiment" - these are conditions that ensure the adequacy of the obtained results)... Otherwise - about "shampooing"! :)))
And you call this process (9 pages long) "finding interesting solutions"? :)))
On the 1st page - it was a help on "help", and after the 2nd page there was an interest - "what's the fastest way". BUT the answer to this question implies to contain figures (I already did not mention "purity of experiment" - these are conditions that ensure the adequacy of the obtained results)... :)))