ICSE Class 10 Computer Applications Question 21 of 30

Solved 2024 Question Paper ICSE Class 10 Computer Applications — Question 26

Back to all questions
26
Question

Question 2(vi)

Consider the following two-dimensional array and answer the questions given below:

int x[ ][ ] = {{4,3,2}, {7,8,2}, {8, 3,10}, {1, 2, 9}};

(a) What is the order of the array?

(b) What is the value of x[0][0]+x[2][2]?

Answer

(a) The order of the array is 4 x 3 as it has 4 rows and 3 columns.

(b) The value is evaluated as follows:

x[0][0] = 4
x[2][2] = 10

x[0][0]+x[2][2] = 4 + 10 = 14