Chapter 9, 9.7

1. What are two-dimesional arrays?

– One array with each element is defined by two numbers.

2. Describe an application in which a two-dimensional array might be used.

– To create a table with numerator and denominator.

3.

– for (row=0; row < table.length; row ++)

for (col = 0; table[row]. length; col++)

if (table[row][col] <0)

break;
4. Describe the contents of the array after the following code segment is run:

– It creates a five by five table and assign a value of the product of rows and colums into each spot.

Leave a Comment