Data Types In Java
Primitive Data Types and Referenced Datatypes Premitive Data Types: There are eight primitive data types in Java " boolean" :- the type whose values are either true or false "char" :- the character type whose values are 16-bit Unicode characters (only single character ). ex: 'a' The arithmetic types: The integral types: "byte" (-128 .. 127 numeric range values) "short"(-32,768 .. 32,767 numeric range values) "int"(-2,147,483,648 .. 2,147,483,647 numeric range values ) "long"(-9,223,372,036,854,775,808 .. 9,223,372,036,854,775,807 numeric range values ) The floating-point types "float" "double" Referenced Datatypes: Referenced DataType is a varible defined of a class for example : "String" is a class given in "java.lang" package if we want to represent a string (a group of characters) i.e "abcdef" we need to define a variabl