Assume the following declarations
const int NUMROWS = 3;
const int NUMCOLS = 4;
int val[NUMROWS][NUMCOLS]={8,16,9,52,3,15,27,6,14,25,2,10};
Which statement will change the value of the element with the value 27 to 55.
1. val[0][1] = 55;
2. val[1][2] = 55;
3. val[2][1] = 55;
4. val[1][1] = 55;
1
Expert's answer
2021-08-23T07:29:06-0400
Answer
The value 27 is in row 1 and column 2.
The correct answer is option 2. val[1][2] = 55;
Comments
Leave a comment