Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Only one loop is needed to access each element in a two-dimensional array. Selec

ID: 3575957 • Letter: O

Question

Only one loop is needed to access each element in a two-dimensional array.

Select one:

True

False

When using the assignment statement to assign data to a two-dimensional array, what is coded first?

Select one:

a. array name

b. row subscript

c. column subscript

d. expression

The _____ operator can be used to store data in an element in a two-dimensional array.

Select one:

a. insertion

b. extraction

c. buffering

d. none of the above

Given the following array declaration, what is the value stored in the scores[2][3] element?

int scores[5][5] = {0};

Select one:

a. 0

b. 5

c. 10

d. 25

How many elements will a two-dimensional array with 4 rows and 5 columns contain?

Select one:

a. 9

b. 12

c. 18

d. 20

You refer to each element in a two-dimensional array by the _____.

Select one:

a. array's name

b. element's row subscript

c. element's column subscript

d. all of the above

Before you can use a two-dimensional array in a program, you must initialize it.

Select one:

True

False

What happens if an invalid subscript is used to access a two-dimensional array element?

Select one:

a. error message and program ends

b. program continues

c. type conversion

d. the system will will prompt the user

Given the following array declaration, what is the value stored in the scores[0][0] element?

int scores[5][5] = {5};

Select one:

a. 0

b. 5

c. 10

d. 25

Which of the following statements will declare a two-dimensional array called scores to be of the int data type and contain 3 rows and 4 columns, while also initializing all elements to 0?

Select one:

a. int scores [4][3] = 0;

b. int scores [3][4] = 0;

c. int scores[3][4] = {0};

d. int scores[12] = {0};

The most commonly used array(s) in business applications are _____.

Select one:

a. one-dimensional

b. two-dimensional

c. both a and b

d. none of the above

Explanation / Answer

1) False -- You will need two loops
2) a -- array name
3) a
4) a
5) d
6) d
7) False
8) a
9) a
10) c
11) c