Arrays

Arrays

9th - 12th Grade

20 Qs

quiz-placeholder

Similar activities

M6_Visual Basic_Final Quiz1

M6_Visual Basic_Final Quiz1

10th - 12th Grade

23 Qs

Functions in Python

Functions in Python

9th - 12th Grade

16 Qs

Season 2 #Spaic Python Weekly Quiz

Season 2 #Spaic Python Weekly Quiz

KG - Professional Development

20 Qs

Struktur Kontrol

Struktur Kontrol

10th Grade

17 Qs

Integration

Integration

12th Grade

18 Qs

Computer Hardware

Computer Hardware

11th - 12th Grade

15 Qs

MFAI SOTI Quiz

MFAI SOTI Quiz

12th Grade

20 Qs

C Programming

C Programming

12th Grade - University

25 Qs

Arrays

Arrays

Assessment

Quiz

Other

9th - 12th Grade

Medium

Created by

Brianna Kane

Used 69+ times

FREE Resource

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

Which of the following is FALSE about arrays on Java

A java array is always an object

Length of array can be changed after creation of array

Arrays in Java are always allocated on heap

2.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

What is the length of the following array: byte[] data = { 12, 34, 9, 0, -62, 88 };

1

5

6

12

3.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

How will you identify a single array?
single curly brackets
single square brackets
multiple squares brackets
single angled brackets

4.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

What are the legal indexes for the array ar, given the following declaration:

int[] ar = {2, 4, 6, 8 };

0, 1, 2, 3

1, 2, 3, 4

2, 4, 6, 8

0, 2, 4, 6

5.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

What does the following segment of code print out? int[] numArray = { 2, 7, 4, 12, 0, 2 };
System.out.println("Number: " + numArray[2]);
Number: 2
Number: 7
Number: 4
Number: 12

6.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

What does the following segment of code print out? int[] numArray = { 2, 7, 4, 12, 0, 2 };
System.out.println("Number: " + numArray[0]);
Number: 2
Number: 7
Number: 4
Number: 12

7.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

What does the following segment of code print out? int[] numArray = { 2, 7, 4, 12, 0, 2 };
System.out.println("Number: " + numArray[numArray.length - 1]);
Number: 2
Number: 0
Number: 12
Number: 6

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?