Wednesday, December 25, 2013

Primitive Data Types in Java




http://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html

Type
Explanation
Default Value, Minimum, Maximum
Example
byte
A 8-bit (1-byte) integer value
0
-127
127
byte b = 1;
short
A 16-bit (2-byte) integer value
0
-32,768
32,767
short s = 10;
int
A 32-bit (4-byte) integer value
0
-2,147,483,648
2,147,483,647
int i = 32;
long
An 64-bit (8-byte) integer value
0L
-263
263-1
long l = 100L;
float
A 32-bit (4-byte) floating-point value
0.0f


float f = 150.5f ;
double
A 64-bit (8-byte) floating-point value
0.0d


double d = 155.5d;
boolean
true or false value
false



char
A 16-bit character using the Unicode encoding scheme
‘\u000’



1 comment:

  1. ᐈ토토 배당 계산법, Casinofib 카지노 카지노 matchpoint matchpoint ミスティーノ ミスティーノ 20Merkur Progress 570 - Agen Judi Slot Online Gacor, Title

    ReplyDelete