Arrays in Java
Quiz
•
Computers
•
9th - 12th Grade
•
Medium
Jharna Marwah[UHD]
Used 238+ times
FREE Resource
Enhance your content in a minute
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Find the output
class Test {
public static void main(String args[]) {
int arr[2];
System.out.println(arr[0]);
System.out.println(arr[1]);
}
}
Compile error
Exception
Garbage value
Garbage value
0
0
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Find the output
class Test {
public static void main(String args[]) {
int arr [ ] = new int[2];
System.out.println(arr[0]);
System.out.println(arr[1]);
}
}
Compile error
Exception
Garbage value
Garbage value
0
0
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
class Demo1
{
public static void main(String args[])
{
int i[] = new int[0];
System.out.println(i[0]);
}
}
0
Exception
Garbage value
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
class Demo1
{
public static void main(String args[])
{
int i[] = new int[10];
System.out.println(i[10]);
}
}
0
Garbage value
Out of bound exception
Error
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How will you identify a single dimensional array?
single curly brackets
single square brackets
multiple squares brackets
single angled brackets
6.
MULTIPLE CHOICE QUESTION
30 sec • Ungraded
If the data is in order the best search to use would be a______
Binary Search
Linear Search
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is returned by values[5]?
2
12
6
8
Create a free account and access millions of resources
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
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?
Similar Resources on Wayground
16 questions
Java by Mr Sam
Quiz
•
10th Grade
20 questions
Тривимірна графіка. Основи роботи в Blender
Quiz
•
12th Grade
15 questions
Javascript Quiz 2
Quiz
•
11th Grade
16 questions
IBA Chapter 8B
Quiz
•
8th - 12th Grade
16 questions
Boolean and Search Operators
Quiz
•
9th - 12th Grade
16 questions
DATA SCIENCE Assessment (April)
Quiz
•
8th - 12th Grade
20 questions
End of year quiz: Python
Quiz
•
9th Grade
17 questions
ÔN TẬP CUỐI KỲ II TIN 8
Quiz
•
8th - 11th Grade
Popular Resources on Wayground
20 questions
Halloween Trivia
Quiz
•
6th - 8th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
15 questions
Order of Operations
Quiz
•
5th Grade
20 questions
Halloween
Quiz
•
5th Grade
16 questions
Halloween
Quiz
•
3rd Grade
12 questions
It's The Great Pumpkin Charlie Brown
Quiz
•
1st - 5th Grade
20 questions
Possessive Nouns
Quiz
•
5th Grade
10 questions
Halloween Traditions and Origins
Interactive video
•
5th - 10th Grade
