The type declaration character of Single is exclamation mark (! )。 Double data type Double (double-precision floating-point type) variables are stored as IEEE 64-bit (8-byte) floating-point values.
The range of values is-1.7913486232e308 to -4.99654 1247e-324, and when it is negative, it ranges from 4.99438+0247e-324. The type declaration character of Double is a number symbol (#).
Extended data:
Because floating-point numbers (including Double) are stored in the form of k ÷ (2 n) (where both k and n are integers), although 30/3 is equal to 10, it cannot be accurately saved in the computer at this time, and only an approximate value can be saved. When dealing with floating-point numbers, don't expect accurate results.
(1) expansion. Single data type extended to double data type. This means that you can convert a single precision to a double precision without the System.OverflowException.
(2) trailing zero. Floating-point data types do not have any internal representation of trailing 0 characters. For example, they can't tell 4.2000 from 4.2. Therefore, when displaying or outputting floating-point values, trailing 0 characters will not appear.
(3) Type characters. When the text type character "f" is attached to the text, it will be converted to a single data type. Identifier type character "!" Attaching to any identifier will force it to be single.
(4) Frame type. The corresponding type in. NET framework is a system. Single structure.
Baidu Encyclopedia-Single Data Type