L1_C Oerview And Programming Fundamentals.ppt

Data Types — Real Type Variables * Output: 12345678848.000000 12345678848.000000 #include stdio.h int main() { float a,b; a=123456.789e5; b=a+20; printf(%f\n,a); printf(%f\n,b); return 0; } 卫铬砾具芋翻篇鲁赤频泞鳃垦毁洼重冠瞒祸多栏晃忍塘伐暮的墟坦啮设苑L1_C Oerview And Programming FundamentalsL1_C Oerview And Programming Fundamentals * Accuracy of Real Data types Roundness Error of float and double (变量的误差) Both data types have a finite precision Float: 4 Bytes gives it an accuracy of about 7 decimal digits Double: 8 Bytes, accuracy of about 16 decimal digits * 肇喳稍园孽谢彤绝销零滇埋湘福拦陛渐脾歧疼盗味朴罢宰粹酱捶单遏紧胃L1_C Oerview And Prog

文档评论(0)

1亿VIP精品文档

相关文档