Visual Basic - 32-bit real number: single

32-bit real number and his value range: from -3.4 × 10 on 38 to +3.4 × 10 on 38 and it has 7 digit precision. this means that it is true that we can into it save big numbers but we must calculate that over number 7 will be rounding. for example, it can be used for storing large numbers, where are not so important the smaller parts, or in the case of small integers with a fraction. if it is used to store integers the biggest integer what can store without rounding is 2 on 24. 32-bit real number is stored the following way: 1bit sign, 8bit exponent and 23bit mantissa.



Used keywords: single


Visual Basic .NET

32-bit real number the possible of use:
Dim x As single= 3.14159265359  ' x = 3.14159274
Dim y As single= 123456789      ' y = 123456792.0
y =CSng((x * y))       ' z = 387850976.0

you can find it in the following collections: real numbers | numbers | data types
Languages: en hu cz sk