2024年4月20日

摘要: public static void main(String[] args) { int [] arrays= {1,2,3,4,5}; printArrary(arrays); } //打印数组元素 public static void printArrary(int[] arrays){ for 阅读全文
posted @ 2024-04-20 18:08 anonymity。 阅读(8) 评论(0) 推荐(0)
 
摘要: public class Dmo03 { public static void main(String[] args) { int [] arrays={1,2,3,4,5}; //打印全部的数组元素 for (int i=0;i< arrays.length;i++){ System.out.pr 阅读全文
posted @ 2024-04-20 15:32 anonymity。 阅读(14) 评论(0) 推荐(0)
 
摘要: public class Demo01 { public static void main(String[] args) { int [] nums;//1.声明一个数组 nums =new int[10];//2.创建一个数组 //声明并创建一个数组 int [] nums2 =new int[1 阅读全文
posted @ 2024-04-20 10:32 anonymity。 阅读(23) 评论(0) 推荐(0)