Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
Selected Reading
Difference Between Float and Double
In this post, we will understand the difference between float and double data types.
float
It has a single precision.
It takes 4 bytes of memory.
According to IEEE, it has 32-bit precision.
It is used with graphic based libraries.
It improves the processing power of programs.
It is simple to manage by compilers.
Its value can be between 1.2E-38 to 3.4E+38.
It can have a precision of up to 6 decimal places.
double
It has a double precision.
It takes 8 bytes of memory.
According to IEEE, it has 64-bit precision.
Its value can be between 2.3E-308 to 1.7E+308.
It can have a precision of up to 15 decimal places.
It is considered as the most commonly used data type.
Advertisements
