Java Reference
In-Depth Information
Range -32,768 to 32,767
Used in larger arrays to save memory space
Long
64 bit signed integer
Minimum value is -9,223,372,036,854,775,808 and Maximum value is
9,223,372,036,854,775,807
This data type is used if there is a need of higher range than Int.
Default value for Long data type is 0L
Float
Single precision 32bit IEEE 754 floating point.
Float is used to deal with larger array of floating point numbers to
save the memory.
Default value for Float data type is 0.0f.
Double
Double precision 64 bit IEEE 754 floating point.
Default data type / choice for decimal values
Default value for Double data type is 0.0d.
Boolean
Boolean data types represent 1 bit information
There are only two possible values for Boolean data types i.e true and
false
Boolean data types are mainly used in condition checking.
Search WWH ::




Custom Search