Which of the following is FALSE about arrays on Java
(A) A java array is always an object
(B) Length of array can be changed after creation of array
(C) Arrays in Java are always allocated on heap
Explanation: In Java, arrays are objects, they have members like length. The length member is final and cannot be changed.
All objects are allocated on heap in Java, so arrays are also allocated on heap.
Quiz of this Question
- Java.util.Arrays.parallelSetAll(), Arrays.setAll() in Java
- Java | Arrays | Question 4
- Java | Arrays | Question 2
- Java | Arrays | Question 8
- Java | Arrays | Question 7
- Java | Arrays | Question 6
- Java | Arrays | Question 5
- Java | Arrays | Question 3
- Arrays in Java
- Iterating over Arrays in Java
- Arrays class in Java
- Final arrays in Java
- Arrays.deepToString() in Java with Example
- How to compare two arrays in Java?
- Multidimensional Arrays in Java