04 2021 档案

摘要:1.编写一个简单程序,要求数组长度为5,分别赋值10,20,30,40,50,在控制台输出该数组的值 package School.Day9; public class Test01 { public static void main(String[] args) { int[] a = {10, 阅读全文
posted @ 2021-04-24 14:02 李芊 阅读(93) 评论(0) 推荐(0)
摘要:1.编写一个简单程序,要求数组长度为5,静态赋值10,20,30,40,50,在控制台输出该数组的值。 package School.Day8; public class Test01 { public static void main(String[] args){ int[] x = {10,2 阅读全文
posted @ 2021-04-16 16:42 李芊 阅读(70) 评论(0) 推荐(0)
摘要:1.使用for循环计算1-100的和,除了以3结尾的那些数 package School.Day7; public class Test01 { public static void main(String[] args){ int sum = 0; for(int i = 1;i<=100;i++ 阅读全文
posted @ 2021-04-09 16:43 李芊 阅读(84) 评论(0) 推荐(0)
摘要:1.分别使用for循环,while循环,do循环求1到100之间所有能被3整除的整数的和。 package School.Day6; public class Test03 { public static void main(String[] args){ int i = 1; int sum = 阅读全文
posted @ 2021-04-04 21:48 李芊 阅读(74) 评论(0) 推荐(0)