- www.mql5.com
Comment(StringFormat("Equity is %.2f", AccountEquity()));
Floating-point has an infinite number of decimals, it's you, not understanding floating-point and that some numbers can't be represented exactly. (like 1/10.)
Double-precision floating-point format - Wikipedia
See also The == operand. - MQL4 programming forum (2013)
If you want to see the correct number of digits, convert it to a string with the correct/wanted accuracy.
question about decima of marketinfo() - MQL4 programming forum (2016)
Floating-point has an infinite number of decimals, it's you, not understanding floating-point and that some numbers can't be represented exactly. (like 1/10.)
Double-precision floating-point format - Wikipedia
See also The == operand. - MQL4 programming forum (2013)
If you want to see the correct number of digits, convert it to a string with the correct/wanted accuracy.
question about decima of marketinfo() - MQL4 programming forum (2016)
Floating-point has an infinite number of decimals, it's you, not understanding floating-point and that some numbers can't be represented exactly. (like 1/10.)
Double-precision floating-point format - Wikipedia
See also The == operand. - MQL4 programming forum (2013)
If you want to see the correct number of digits, convert it to a string with the correct/wanted accuracy.
question about decima of marketinfo() - MQL4 programming forum (2016)
I will use float or double. Why do I need to know how numbers are stored in memory?
Because ignorance is dangerous and can cause you to write bad code, and in the case of trading, cause you to lose money.
When you understand something it is easier to write proper code with less errors, and be able to understand the reason why. And when something goes wrong, it will be easier to fix.
Because ignorance is dangerous and can cause you to write bad code, and in the case of trading, cause you to lose money.
When you understand something it is easier to write proper code with less errors, and be able to understand the reason why. And when something goes wrong, it will be easier to fix.
I'll have to hang out on mql5.com more rarely and reduce my ignorance. Thanks for answers. Still didn't get what floating-point is and why I needed this concept in that code ;)
You can explain everything in a simple way that a five-year-old child will understand, but for some reason you use the most complex explanation or the words "ignorant" when it is already clear, instead of understanding it as characteristic of a person who does not distinguish between Round and NormalizeDouble .
Where should I go to study instead of mql5.com? It's very difficult here.
I'll have to hang out on mql5.com often and reduce my ignorance. Thanks for answers. But still didn't get what floating-point is and why I needed this concept in that code ;)
You can explain everything in a simple way that a five-year-old child will understand, but for some reason you use the most complex explanation or the words "uneducated" when it is already clear, instead of understanding it as characteristic of a person who does not distinguish between Round and NormalizeDouble. Where should I go to study instead of mql5.com? It's very difficult here.
According to your profile, you are from Russia. If it is easier for you to learn in your language, then there is the both the Russian forum as well as Russian documentation.
I just confused the concepts of "format" and "round" and had no idea what "NormalizeDouble" was at all. I just trusted some MQL programmer guru on YouTube and started practicing. Understand me. I program for 1 week.
I'll have to hang out on mql5.com more rarely and reduce my ignorance. Thanks for answers. Still didn't get what floating-point is and why I needed this concept in that code ;)
You can explain everything in a simple way that a five-year-old child will understand, but for some reason you use the most complex explanation or the words "ignorant" when it is already clear, instead of understanding it as characteristic of a person who does not distinguish between Round and NormalizeDouble .
Where should I go to study instead of mql5.com? It's very difficult here.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use