返回列表 發帖
  1. public class Ch01
  2. {
  3.     public static void main(String args[])
  4.     {
  5.         int a[]={1,2,3,4};
  6.         int b[][]={{1,2,3,4},{1,2,3,4},{1,2,3,4}};
  7.         int c[][][]={{{1,2,3,4},{1,2,3,4},{1,2,3,4}},{{1,2,3,4},{1,2,3,4},{1,2,3,4}}};
  8.         
  9.         System.out.println(a.length);     
  10.         System.out.println(b.length);     
  11.     }
  12. }
複製代碼

TOP

  1. public class ch01
  2. {
  3.     public static void main(String args[])
  4.     {
  5.         int a[]={1,2,3,4};
  6.         int b[][]={{1,2,3,4},{1,2,3,4},{1,2,3,4}};
  7.         int c[][][]={{{1,2,3,4},{1,2,3,4},{1,2,3,4}},{{1,2,3,4},{1,2,3,4},{1,2,3,4}}};
  8.         System.out.println(a.length);
  9.         System.out.println(b.length);
  10.         System.out.println(c.length);
  11.     }
  12. }
複製代碼

TOP

返回列表