java - Initialized 2d array of int prints out zero -


i'm trying initialize 2d array using braces notation follows:

int[][] matrix = {{0, 2, 1}, {1, 2, 3}, {3, 2, 1}}; int[][] out = rotate(matrix);  for(int = 0; < 3; i++){     for(int j = 0; j < 3; j++){         system.out.print(matrix[i][j] + " ");     }     system.out.println(""); } 

for output, getting

0 0 0   0 0 0   0 0 0  

can tell me problem?


Comments

Popular posts from this blog

mysql - FireDac error 314 - but DLLs are in program directory -

git - How to list all releases of public repository with GitHub API V3 -

c++ - Getting C2512 "no default constructor" for `ClassA` error on the first parentheses of constructor for `ClassB`? -