How to declare, create, initialize and access an array in Java?
Answers
Answered by
0
To declare : Datatype arrayname[ ]
int a[ ]
This is syntax to declare and initialise together .
Syntax : Datatype array name [ ] =new Datatype[ size];
int a[ ]= new int [10];
Hope you will get it
For more java doubts follow me@
Similar questions
English,
7 months ago
English,
7 months ago
India Languages,
7 months ago
Computer Science,
1 year ago
Psychology,
1 year ago
Math,
1 year ago