+ 1

What is the difference between float and double?

Can anyone explain?

8th Jun 2019, 9:43 AM
Parth Lakhani
Parth Lakhani - avatar
10 Answers
+ 13
ā€¢ Schildt, H. (2003). C++: Complete Reference. 4th ed. New York: McGraw-Hill. Ch. 2. The range of 'float' and 'double' will depend upon the method used to represent the floating-point numbers. ( Whatever the method, the range is quite large. ) The minimum number of digits of precision for each floating-point type is: ā€¢ float Typical Size in Bits ā€” 32 Minimal Range ā€” Six digits of precision ā€¢ double Typical Size in Bits ā€” 64 Minimal Range ā€” Ten digits of precision
8th Jun 2019, 10:45 AM
Danijel Ivanović
Danijel Ivanović - avatar
8th Jun 2019, 6:57 PM
AĶ¢J
AĶ¢J - avatar
+ 3
double have longer precision than float, and a double is twice the size of float
8th Jun 2019, 9:50 AM
āœ³AsterisKāœ³
āœ³AsterisKāœ³ - avatar
+ 2
Parth Lakhani about the difference or what???
8th Jun 2019, 9:53 AM
āœ³AsterisKāœ³
āœ³AsterisKāœ³ - avatar
+ 2
Parth Lakhani longer precision = more digits behind the dot.
8th Jun 2019, 9:54 AM
luŹi
+ 1
Want some depth knowledge about it *AsterisK*
8th Jun 2019, 9:52 AM
Parth Lakhani
Parth Lakhani - avatar
+ 1
Difference *AsterisK*
8th Jun 2019, 9:53 AM
Parth Lakhani
Parth Lakhani - avatar
+ 1
Thank you guys i understood nowšŸ˜Š
8th Jun 2019, 11:54 AM
Parth Lakhani
Parth Lakhani - avatar