以下哪个是正确的语句?().
A: char[][] charArray = {'a', 'b'};
B: char[2][2] charArray = {{'a', 'b'}, {'c', 'd'}};
C: char[2][] charArray = {{'a', 'b'}, {'c', 'd'}};
D: char[][] charArray = {{'a', 'b'}, {'c', 'd'}};
A: char[][] charArray = {'a', 'b'};
B: char[2][2] charArray = {{'a', 'b'}, {'c', 'd'}};
C: char[2][] charArray = {{'a', 'b'}, {'c', 'd'}};
D: char[][] charArray = {{'a', 'b'}, {'c', 'd'}};
举一反三
- 以下哪个是正确的语句?() A: char[][]<br/>charArray = {'a', 'b'}; B: char[2][2]<br/>charArray = {{'a', 'b'}, {'c', 'd'}}; C: char[2][]<br/>charArray = {{'a', 'b'}, {'c', 'd'}}; D: char[][]<br/>charArray = {{'a', 'b'}, {'c', 'd'}};
- 下列声明二维数组的语句不合法的是() A: char c[][] = new char[2][3]; B: char c[][]=new char[6][]; C: char[][] c= new char[3][3]; D: char [][] c = new char[][4];
- 下列数组的定义不合法的是() A: char c[][]=new char[2][4] B: char c[][]=new char[2][] C: char [][]c=new char[][3] D: int []a[] = new int[5][5]
- 下列语句中,不正确的是()。 A: char a[2]={'1'}; B: char a[2]={1,2}; C: int a[2]={'1','2'}; D: char a[2]={'1','2','3'};
- 下面关于数组的初绐化正确的是( )。? char str()={′a′,′b′,′c′};|char str[2][3]={ {′a′,′b′}, {′c′,′d′}, {′e′,′ f′} };|char str[ ]={'a', 'b', 'c'};|char str[2]={'a', 'b', 'c'};