Advertisement

Udemy WW Udemy WW

Saturday, 10 December 2011

Class name for Array in java

For Java arrays,the class name is '[' followed by an encoded name of the element class. The number of  '[' character represent the number of dimension of the array
Element Type  Encoding
byte                     B
boolean               Z
char                    C
double                D
float                   F
int                      I
long                   J
short                  S
class or interface   L classname; 

for example : for float type array class name is   [F
for int [I
for double a[][]=new double[2][3]
class name id [[D

No comments:

Post a Comment

Advertisement

Udemy WW