Commit 720bed6
committed
feat: Print elements of a 2D array with variable column lengths (jagged array)
🧠 Logic:
- Initializes a 2D jagged array where each row has a different number of columns.
- Iterates through each row and its corresponding columns using nested loops.
- Prints elements row by row, handling non-uniform (non-rectangular) structure safely.
Signed-off-by: Somesh diwan <[email protected]>1 parent 8cb16c0 commit 720bed6
1 file changed
+4
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
10 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
11 | 13 | | |
12 | 14 | | |
13 | 15 | | |
| |||
0 commit comments