290114lyp

导航

2022年10月27日

增强for循环

摘要: 增强for循环 for(声明语句:表达式) { //代码句子 } package com.jiemo.struct;public class ForShabi5 { public static void main(String[] args) { int[] numbers={10,20,30,40 阅读全文

posted @ 2022-10-27 13:51 是芥末!日 阅读(10) 评论(0) 推荐(0) 编辑

用for打印九九乘法表

摘要: package com.jiemo.struct;public class ForShabi4 { public static void main(String[] args) { //1.先打印第一列 //2.把固定的i再用一个循环包起来 //3.去掉重复项,i<=j //4.调整样式 for ( 阅读全文

posted @ 2022-10-27 13:38 是芥末!日 阅读(11) 评论(0) 推荐(0) 编辑

For 循环

摘要: For 循环 for(初始化;布尔表达式;更新){ //代码语句 } package com.jiemo.struct;public class ForShabi1 { public static void main(String[] args) { int a = 1;//初始化条件 while 阅读全文

posted @ 2022-10-27 13:15 是芥末!日 阅读(52) 评论(0) 推荐(0) 编辑