2D Array Review

2D Array Review

Assessment

Interactive Video

Computers

9th - 12th Grade

Easy

Created by

Myra Deister

Used 2+ times

FREE Resource

9 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What type of data structure is used to represent the apartment rent information?

ArrayList

2D Array

1D Array

Hash Table

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How many floors does the apartment building have?

2

3

4

5

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which two pieces of information are needed to determine a tenant's rent?

Floor and apartment square footage

Floor and number of bedrooms

Number of bedrooms and tenant's income

Floor and tenant's age

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In a two-dimensional array, how many subscripts are used to access an element?

1

2

3

4

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the relationship between floor number and rent price?

Lower floors have higher rent

Higher floors have higher rent

All floors have the same rent

Rent is randomly assigned per floor

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

When initializing the two-dimensional array, what symbols are used to enclose each row of elements?

Parentheses ()

Square brackets []

Curly brackets {}

Angle brackets <>

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Why did the initial test of the program return an incorrect value?

The array was not properly initialized

The user input was invalid

The program didn't account for indexing beginning at zero

There was a typo in the array values

8.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How was the issue with incorrect array access resolved?

By changing the array values

By subtracting 1 from the floor input

By adding 1 to the bedroom input

By reordering the array elements

9.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

 What would happen if the bedroom numbering started at 1 instead of 0?

The program would work without changes

The array would need to be restructured

The bedroom variable would need to be adjusted when accessing the array

The floor variable would need to be adjusted