Quiz 16 - Arrays and Loops

Quiz
•
Computers
•
11th Grade
•
Medium
Casey Devet
Used 69+ times
FREE Resource
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
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
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
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
Similar Resources on Wayground
10 questions
Programming - Arrays

Quiz
•
2nd - 12th Grade
10 questions
8.2 Arrays Cambridge IGCSE 0478

Quiz
•
10th Grade - University
6 questions
Arrays

Quiz
•
11th Grade
12 questions
Java - arrays and String methods

Quiz
•
9th - 12th Grade
10 questions
AutoCad Practice Exam

Quiz
•
10th - 11th Grade
10 questions
H466 - Arrays, Records, Tuples and Lists

Quiz
•
11th Grade - University
7 questions
Topic 6.1 Video 1

Quiz
•
11th Grade
12 questions
4B_java_Novembre2021

Quiz
•
11th Grade
Popular Resources on Wayground
18 questions
Writing Launch Day 1

Lesson
•
3rd Grade
11 questions
Hallway & Bathroom Expectations

Quiz
•
6th - 8th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
40 questions
Algebra Review Topics

Quiz
•
9th - 12th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
19 questions
Handbook Overview

Lesson
•
9th - 12th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
Discover more resources for Computers
40 questions
Algebra Review Topics

Quiz
•
9th - 12th Grade
19 questions
Handbook Overview

Lesson
•
9th - 12th Grade
40 questions
LSHS Student Handbook Review: Pages 7-9

Quiz
•
11th Grade
20 questions
Scalars, Vectors & Graphs

Quiz
•
11th Grade
62 questions
Spanish Speaking Countries, Capitals, and Locations

Quiz
•
9th - 12th Grade
10 questions
Solving Equations Opener

Quiz
•
11th Grade
20 questions
First Day of School

Quiz
•
6th - 12th Grade
21 questions
Arithmetic Sequences

Quiz
•
9th - 12th Grade