这里有详细的介绍
ms-help://MS.VSCC/MS.MSDNVS/csref/html/vcrefTheDecimalType.htm可以表示这么大的数:
Your amount = $9,999,999,999,999,999,999,999,999,999.00
ms-help://MS.VSCC/MS.MSDNVS/csref/html/vcrefTheDecimalType.htm可以表示这么大的数:
Your amount = $9,999,999,999,999,999,999,999,999,999.00
float d = 1.0f;
这是安装msdn后的 在本机上的连接,不是internet上的
-----MSDN-----
Literals
If you want a numeric real literal to be treated as decimal, use the suffix m or M, for example:
decimal myMoney = 300.5m;
Without the suffix m, the number is treated as a double, thus generating a compiler error.
-----MSDN-----
用m或M后缀是为了让编译器区分 decimal 类型和 double类型