‹ Back to the paper
What is the conditional statement to check for the Non-boundary elements in a double dimensional…
What is the conditional statement to check for the Non-boundary elements in a double dimensional array of ‘M’ number of rows and ‘N’ number of columns? The row index is represented by ‘r’ and the column index is represented by ‘c’.
- (a)(r>0 || r<M-1 && c>0 || c<N-1)
- (b)(r>0 && r<M-1 || c>0 && c<N-1)
- (c)(r>0 && r<M-1 && c>0 && c<N-1)
- (d)(r>0 || r<M-1 || c>0 || c<N-1)
Answer
No answer yet.
From ISC 2022 Computer Science - Specimen paper (Semester 1), Paper 1, question 19.