Opening the reading…
Opening the reading…
DSA FUNDAMENTALS › MATRIX BASICS
This is a scratch drill — your code runs, nothing is graded or recorded. No test cases, no expected output, no verdict.
TASK
Complete the marked condition in the nested loops so the Java program prints every boundary value of the 4 x 5 matrix exactly once in row-wise order and skips all interior values.
OUTPUT
Sample1 2 3 4 5 6 10 11 15 16 17 18 19 20
What a finished answer prints, from the lesson. Nothing has run yet — press Run and this is replaced by your program’s own output.