摘要:
1、普通for循环 for(初始化; 布尔表达式; 更新变化条件){ //循环执行的内容 } //举例 for(int i=0; i<20;i++){ System.out.println(i); } 2、增强for循环 for(声明变量量类型:被遍历的集合(collection)或者数组){ // 阅读全文
posted @ 2021-03-08 20:44
被梦想尘封的时光
阅读(434)
评论(0)
推荐(0)
摘要:
1、字符串数组 //定义字符串数组String[] s=new String[6]; //定义字符串数组并赋值String[] str=new String[]{"a","b","c"};String[] str2={"a","b","c"} 2、整形数组 //定义整型数组int[] i=new i 阅读全文
posted @ 2021-03-08 20:39
被梦想尘封的时光
阅读(2596)
评论(0)
推荐(0)

浙公网安备 33010602011771号