Integer Array Instantiation
Which of the following options correctly instantiates an array of 5 integers named testGrades?
A
int testGrades[] = new int(5);
B
int[] testGrades = new int[5];
C
int testGrades = new int[5];
D
int[] testGrades = {5};
Question Leaderboard
| Rank | |||||
|---|---|---|---|---|---|
| #1 | bommasam000 | 3 | 3 | 1m 24s | 216 |
| #2 | singhris000 | 1 | 1 | 0m 19s | 81 |
| #3 | y.seong2027 | 1 | 1 | 1m 06s | 34 |
| #4 | sailajavadlamani33 | 1 | 2 | 1m 44s | -14 |
Items per page:
10
1 – 4 of 4
APFIVE