← Quiz: Matrix Programs in C: all 10 questions
Quiz: Matrix Programs in C · Question 10 of 10
In the spiral-order program, why are there checks before printing the bottom row and the left column?
In the spiral-order program, why are there checks before printing the bottom row and the left column?
- A.To print the matrix faster
- B.To skip the corner values on purpose
- C.When only one row or column remains, printing them again would repeat values
- D.Because C does not allow loops that count down
Answer & explanation
Correct answer: When only one row or column remains, printing them again would repeat values
After the top row and right column are printed, the bottom row or left column may no longer exist.
Can you get the rest right without peeking?
Take the timed Quiz: Matrix Programs in C quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →