多項(xiàng)選擇題

Which code fragments will succeed in initializing a two-dimensional array named tab with a size that will cause the expression tab[3][2] to access a valid element?()  
CODE FRAGMENT a:  int[][] tab = {  { 0, 0, 0 },  { 0, 0, 0 }  };  
CODE FRAGMENT b:  int tab[][] = new int[4][];  for (int i=0; i  
CODE FRAGMENT c:  int tab[][] = {  0, 0, 0, 0,  0, 0, 0, 0,  0, 0, 0, 0,  0, 0, 0, 0  };  
CODE FRAGMENT d:  int tab[3][2];  
CODE FRAGMENT e:  int[] tab[] = { {0, 0, 0}, {0, 0, 0}, {0, 0, 0}, {0, 0, 0} };  

A.Code fragment a.
B.Code fragment b.
C.Code fragment c.
D.Code fragment d.
E.Code fragment e.

微信掃碼免費(fèi)搜題