Learn about significant figures after decimal point, we have the largest and most updated significant figures after decimal point information on alibabacloud.com
Transferred from: http://www.cnblogs.com/lovewife/articles/2466543.htmlSingle precision refers to a 4-byte floating-point number, which is the floatA double is a 8-byte floating-point number, which is doubleDecimal is a high precisionFloating point
It's always strange why a decimal is added to the pre-defined data type of C #. Isn't float and double enough? I am going to dig it out today.
Floating Point Type
Name
CTS Type
De script ion
Significant Figures
Range
It's been weird. Why is a decimal added to the predefined data types of C #, and is it enough to have float and double? Come and dig a hole today.
Floating-point type
Name
CTS Type
De script ion
Significant figures
Range
Turn from pencilWhy can floating point numbers lose precision?Floating-point decimal values typically do not have the exact same binary representation. This is a side effect of the floating-point data representation used by the CPU. For this reason,
Original URL: http://blog.sina.com.cn/s/blog_827d041701017ctm.htmlQuestions raised: 12.0f-11.9f=0.10000038, "Lose The Endless" why?An explanation from MSDN:Http://msdn.microsoft.com/zh-cn/c151dt3s.aspxWhy floating-point numbers may lose precision
Questions raised: 12.0f-11.9f=0.10000038, "Lose The Endless" why?Now let's analyze in detail why a floating point operation causes loss of precision.1, Decimal binary representation problemFirst of all, we need to figure out the following two
3.3 Numeric data typesFrom the moment we open our eyes every morning, we deal with numbers almost every hour: from 6:30 on the alarm clock to the 216 bus to work, from the news that the house price fell to 100 yuan per square meter to go home to buy
3.3 Numeric data typesFrom the moment we open our eyes every morning, we deal with numbers almost every hour: from 6:30 on the alarm clock to the 216 bus to work, from the news that the house price fell to 100 yuan per square meter to go home to buy
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.