Professional Documents
Culture Documents
By
Numeric Non-Numeric
Classes
Arrays
Character Boolean
Integer Floating Point
(2) (1)
Interface
VIT - SITE
4 8/19/2016
Data Types
Integer
Floating Point
VIT - SITE
5 8/19/2016
Primitive Data Types
byte E.g.
10
short -15
int 30000
long 555
4567
6 VIT - SITE 8/19/2016
Primitive Data Types
25.6
float 44.567
double -23.46
a
char \u0000
boolean true / false
128 128
float 32 bits
double 64 bits
char 16 bits - Unicode
boolean JVM Dependent
Ariane 5
11 VIT - SITE 8/19/2016
Default values
byte
short
int
long
0
float
double
char 0.0
- \u0000
boolean - false
Explicit Casting
short c = 234;
byte d = (byte)c;
(We need to explicitly mention to cast)