What is primitive data type in java

Java had eight (8) primitive data type.

1) byte                  Width : 8 Range : -128 to 127

2) short                 Width : 16 Range : -32768 to 32767

3)int                       Width : 32 Range : -2147483648 to 2147483647

4) long                   Width : 64 Range : -9223372036854775808 to 9223372036854775807

Above four primitive data type belongs to Integers.

5) float                  Width : 32 Range 1.4e-045 to 3.4e+308

6) double             Width : 64 Range 4.9e-324 to 1.8e+308

Above two primitive data type belongs to Floating Point Types.

7) boolean

8) char

Comments

Recent Post

Recent Posts Widget

Popular posts from this blog

Capture image from webcam java code, examples

How to capture finger prints in java

Shallow Copy Deep Copy Java example