
Java Arrays
Quiz
•
Computers
•
University
•
Practice Problem
•
Medium
Ms N Suganya CSE - 2700
Used 1+ times
FREE Resource
Enhance your content in a minute
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is missing in the following array declaration?___[] arr;
int
float
double
char
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is missing in the following array initialization?int[] arr = ___;
{1,2,3}
new int[] {1, 2, 3}
new int[3]
new int()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is missing in the following array creation?int[] arr = new int[___];
size
10
length
size()
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the error in the following code?int[] arr = {1, 2, 3};
System.out.println(arr[3]);
ArrayIndexOutOfBoundsException
NullPointerException
Syntax Error
No Error
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is missing in the following multi-dimensional array declaration?int[][] arr = new int[3][___];
3
size
columns
length
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the error in the following code?int[] arr;
arr[0] = 10;
ArrayIndexOutOfBoundsException
NullPointerException
Uninitialized Array Error
No Error
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is missing in the following array element assignment?int[] arr = new int[5];
arr[2] = ___;
5
10
arr[0]
all of the above
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
15 questions
PYTHON UNIT I MCQS
Quiz
•
University
11 questions
Python basics
Quiz
•
University
12 questions
AppsLab_Q3
Quiz
•
1st Grade - Professio...
10 questions
KIỂU DỮ LIỆU CÓ CẤU TRÚC
Quiz
•
11th Grade - University
10 questions
Pengantar Coding
Quiz
•
University
12 questions
OOP- Class+Object
Quiz
•
University
10 questions
Control Operations and Instruction Sets Quiz
Quiz
•
University
15 questions
sistema de archivos
Quiz
•
University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
