Quiz 16 - Arrays and Loops

Quiz 16 - Arrays and Loops

11th Grade

10 Qs

quiz-placeholder

Similar activities

1.5.1 - Starter Task/Social Engineering Starter (Dg)

1.5.1 - Starter Task/Social Engineering Starter (Dg)

11th Grade

9 Qs

Computer Fundamental by Pintu Majumder

Computer Fundamental by Pintu Majumder

11th - 12th Grade

15 Qs

Podstawy Pythona

Podstawy Pythona

9th - 12th Grade

10 Qs

CSS (background-position-list)

CSS (background-position-list)

1st Grade - University

10 Qs

Pengantar Modularisasi

Pengantar Modularisasi

11th Grade

10 Qs

Class XI Basics

Class XI Basics

11th - 12th Grade

15 Qs

EXAMEN EXCEL

EXAMEN EXCEL

11th Grade

15 Qs

Pretest หน่วยที่ 4

Pretest หน่วยที่ 4

KG - University

15 Qs

Quiz 16 - Arrays and Loops

Quiz 16 - Arrays and Loops

Assessment

Quiz

Computers

11th Grade

Practice Problem

Medium

Created by

Casey Devet

Used 70+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

Which type of loop is best for iterating through the values of an array?

for loop

while loop

2.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

Which expression will get the length of the array called "ages"?

ages.length()

ages.size()

ages.length

ages.size

3.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

Media Image

This code is supposed to print out all the elements of the array "scores", but it isn't working. What needs to be fixed?

Use <= instead of <

Start index at 0

Use index-- instead of index++

Use > instead of <

4.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

Media Image

This code is supposed to print out all the elements of the array "scores", but it isn't working. What needs to be fixed?

Use < instead of <=

Start index at 1

Use index-- instead of index++

Use >= instead of <=

5.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

Media Image

This code is supposed to print out all the elements of the array "scores", but it isn't working. What needs to be fixed?

Use <= instead of <

Start index at 1

Use > instead of <

Print scores[index] instead of scores

6.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

int size = input.nextInt();


The command above got an integer from the user. Which instruction would create an array with "size" elements?

int [] myArray = new int [size];

int myArray = new int [size];

int [size] myArray = new int [];

int myArray = new int (size);

7.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

What do we call two or more arrays which store related data at the same index?

compact arrays

cooperating arrays

constant arrays

co-related arrays

Create a free account and access millions of resources

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?