上一页 1 ··· 66 67 68 69 70 71 72 73 74 ··· 189 下一页
摘要: #include <stdio.h> //任意输入两个整数,输出这两个数的最大公约数和最小公倍数 main() { int a,b,c,gys,gbs; scanf("%d%d",&a,&b) ; for(c=a;【1】;c--) { if(【2】) { gys=【3】; 【4】; } } gbs= 阅读全文
posted @ 2023-02-17 11:36 myrj 阅读(209) 评论(0) 推荐(0)
摘要: #include <stdio.h> #include <math.h> //根据输入的三角形的三条边判断能否组成三角形,并判断三角形的类型,并输出其面积 //三角形类型区分等边 等腰 等腰直角 直角三角形 main() { float a,b,c,mj,p; scanf("%f%f%f",&a,& 阅读全文
posted @ 2023-02-17 10:33 myrj 阅读(1212) 评论(0) 推荐(0)
摘要: #include <stdio.h> //输出1980-2020年之间所有的闰年,每行三个 main() { int year,【1】,b; for(year=1980;year<=2020;year++) { 【2】; if(【3】) { printf("%5d",year); count++; 阅读全文
posted @ 2023-02-17 10:08 myrj 阅读(678) 评论(0) 推荐(0)
摘要: #include <stdio.h> //用来统计输入的字符中所有大写字母的个数,用#结束输入 main() { int a[26],i; char ch; for(i=0;i<26;i++) a[i]=【1】; ch=getchar(); while(【2】) { if(ch>=65&&ch<=9 阅读全文
posted @ 2023-02-17 09:48 myrj 阅读(565) 评论(0) 推荐(0)
摘要: #include <stdio.h> //功能:从键盘输入一个整数,如果不高于9999则逆序输出,否则打印“输入范围错误" main() { 【1】; 【2】; if(x<=9999) do{ printf("%d",【3】); 【4】; }【5】 else printf("输入范围错误"); ge 阅读全文
posted @ 2023-02-17 09:34 myrj 阅读(128) 评论(0) 推荐(0)
摘要: #include <stdio.h> //功能:从键盘上输入若干学生的成绩,统计并输出最高成绩和最低成绩 //当输入负数时结束输入,请将程序补充完整 main() { float x,amax,amin; scanf("%f",【1】) ; amax=x; amin=x; while(【2】) { 阅读全文
posted @ 2023-02-17 09:27 myrj 阅读(366) 评论(0) 推荐(0)
摘要: #include <stdio.h> //求s=1-3+5-7+...-99+101并输出 main() { int i,t=1,【1】; for(i=1;【2】;【3】) { s=【4】; t=【5】; } printf("s=%d\n",s); getchar(); } 求s=1-3+5-7+. 阅读全文
posted @ 2023-02-17 09:18 myrj 阅读(654) 评论(0) 推荐(0)
摘要: #include <stdio.h> //求s=3+13+23+...+103 main() { int 【1】; for(i=0;【2】;i++) s=【2】; printf("s=【4】\n",s); getchar(); } #include <stdio.h> //求s=3+13+23+.. 阅读全文
posted @ 2023-02-17 09:07 myrj 阅读(295) 评论(0) 推荐(0)
摘要: #include <stdio.h> //找出二维数组中的最大值,并输出所有最大值对应的行与列 main() { int a[5][5]={0,1,2,3,4,5,6,7,8,9,10,11,12,13,24,24,15,16,21,17,18,19,24,22,23} ,max,hang,lie, 阅读全文
posted @ 2023-02-16 19:56 myrj 阅读(407) 评论(0) 推荐(0)
摘要: #include <stdio.h> //求二维数组中的最大值及对应的行号与列号 main() { int a[5][5]={0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,24,15,16,21,17,18,19,20,22,23} ,max,hang,lie,c,b; ma 阅读全文
posted @ 2023-02-16 19:52 myrj 阅读(1184) 评论(0) 推荐(0)
上一页 1 ··· 66 67 68 69 70 71 72 73 74 ··· 189 下一页