Consider the following method declaration. public static void increment(int[][] a) { for (int r = 0; r < a.length; r++) { for (int c = 0; c < a[0].length; c++) { if (a[r][c] >= 0) a[r][c] += 2; else a[r][c] -= 2; } } } Assume the 2D array, matrix, has been initialized to the following values: 2 9 -10 3 0 -4 -10 -4 -1     What is the value of matrix after the method call, increment(matrix);?单项选择题

登录即可查看完整答案

我们收录了全球超50000道真实原题与详细解析,现在登录,立即获得答案。

类似问题

更多留学生实用工具

加入我们,立即解锁 海量真题独家解析,让复习快人一步!