1 /*--------------------------------------------------------------------------*/ 2 /* Name : N19990310_3 */ 3 /* : */ 4 /* Cause : Evaluation order miss, when make integer array. */ 5 /* : */ 6 /* Message : NG:[4]-->[1] */ 7 /*--------------------------------------------------------------------------*/ 8 9 public class N19990310_3 { main(String[] args)10 public static void main(String[] args) { 11 12 int x = 4; 13 14 int ary[][] = new int[x][x=1]; 15 16 if ( ary.length == 4 ) { 17 System.out.println("OK"); 18 } else { 19 System.out.println("NG:[4]-->[" +ary.length+ "]"); 20 } 21 } 22 } 23 24 25