Double is a primitive data type used to store fractional numbers that holds a double-precision floating-point (often 64 bits).
In C and C++ double
must be at least as large as float
(another floating-point type), but its actual size can vary from system to system as it is implementation-defined. It is typically twice the size of float
. Many systems store double
s in binary64, a format described in the IEEE 754 technical standard.
Java has a very strict definition for double
, requiring it to be stored in binary64 (which is also called double-precision).