What is a float and double? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What is a float and double?

As you can tell from the title, what exactly is the variables float ad double? I am very confused. I saw it had something to do with decimal points, but I don't know what exactly it is for.

25th May 2017, 12:33 PM
PoseidonofSea
4 Answers
+ 4
if u wann any floating values in c&c++ than u need to specify the variable with their data type like into,double, float,char and soo on...where float occupy 4bytes where as double 8bytes it means if wann any very large floating number than u should use double...
28th May 2017, 3:45 AM
Bhavin Kanzariya
Bhavin Kanzariya - avatar
+ 3
*not into but int
28th May 2017, 3:46 AM
Bhavin Kanzariya
Bhavin Kanzariya - avatar
+ 2
1.56
25th May 2017, 12:38 PM
Mr. Nobody
Mr. Nobody - avatar