package hlo;public class While {public static void main(String[]args) {int no=2;//0 //2 //5----------> while(no<=5) {"From 2 to 5, inclusive, anything less than or equal to."System.out.println(no);no=no+1; //2=2+1 =3// 3=3+1=4// 4=4+1=5}}}package hlo; public class While { public static void main(String[]args) { int no=2; //0 //2 //5 ----------> while(no<=5) { "From 2 to 5, inclusive, anything less than or equal to." System.out.println(no); no=no+1; //2=2+1 =3 // 3=3+1=4 // 4=4+1=5 } } }package hlo; public class While { public static void main(String[]args) { int no=2; //0 //2 //5 ----------> while(no<=5) { "From 2 to 5, inclusive, anything less than or equal to." System.out.println(no); no=no+1; //2=2+1 =3 // 3=3+1=4 // 4=4+1=5 } } }
Enter fullscreen mode Exit fullscreen mode
原文链接:While Loop Basics
© 版权声明
THE END
暂无评论内容