Programming - Arrays
You Are Here :: Home > JAVA > Arrays - General Questions
1.
An _________ is a container object that holds a fixed number of values of a single type.
A.
Class
B.
array
C.
Object
D.
Method
Answer: Option B
Explanation:
An array is a container object that holds a fixed number of values of a single type.
2.
Each item in an array is called an _________.
A.
method
B.
Object
C.
entity
D.
element
Answer: Option D
Explanation:
Each item in an array is called an element
3.
each element is accessed by its numerical __________.
A.
index
B.
package
C.
Programme
D.
none
Answer: Option A
Explanation:
each element is accessed by its numerical index.
4.
An array's type is written as type[], where typeis the data type of the contained elements; the square brackets are special symbols indicating that this variable holds an array.
A.
objects,classes
B.
methods,classes
C.
elements,square brackets
D.
all the above
Answer: Option C
Explanation:
An array's type is written as type[], where typeis the data type of the contained elements; the square brackets are special symbols indicating that this variable holds an array.
5.
The System class has an arraycopy() method that you can use to efficiently copy data from one array into another:
A.
arraycopy()
B.
arraydiff( )
C.
arraycmp()
D.
both a and b
Answer: Option A
Explanation:
The System class has an arraycopy() method that you can use to efficiently copy data from one array into another:
6.
_______ provides methods to perform some of the most common manipulations related to arrays.
A.
java ME
B.
java EE
C.
Java SE
D.
none
Answer: Option C
Explanation:
Java SE provides methods to perform some of the most common manipulations related to arrays.
next »