一只咖啡君
一只咖啡君
全部文章
分类
归档
标签
去牛客网
登录
/
注册
一只咖啡君的博客
全部文章
(共121篇)
【C】#包含数字9的数#
#include <stdio.h> int main() { int cnt = 0; for(int i = 1; i <= 2019; i++){ int tmp = i; while(tmp){ if...
2022-12-06
2
1524
【C】#魔法数字变换#
#include <stdio.h> int main() { int n, cnt = 0; scanf("%d", &n); while (n != 1) { if (n % 2) n = 3 * n + 1;...
2022-12-06
1
1475
【C】#数位之和#
#include <stdio.h> int main() { int num, sum = 0; scanf("%d", &num); while(num){ sum += num % 10; num /= 10; ...
2022-12-06
1
1507
【C】#牛牛学数列4#
#include <stdio.h> int main() { int n, sum = 0, tmp = 0; scanf("%d", &n); for (int i = 1; i <= n; i++) { tmp += i; ...
2022-12-06
1
1472
【C】#牛牛学数列3#
#include <stdio.h> #include <math.h> int main() { int n; float ret = 0.0, tmp = 0.0; scanf("%d", &n); for(int i = 1; ...
2022-12-06
1
1431
【C】#牛牛学数列2#
#include <stdio.h> int main() { int n; double sum = 0.0; scanf("%d", &n); for (int i = 1; i <= n; i++) { sum += ...
2022-12-06
2
1511
【C】#牛牛学数列#
#include <stdio.h> int main() { int n, sum = 0; scanf("%d", &n); for (int i = 1; i <= n; i++) { if (i % 2 == 0) ...
2022-12-06
1
1441
【C】#乘法表#
#include <stdio.h> int main() { for (int i = 1; i <= 9; i++) { for (int j = 1; j <= i; j++) { printf("%d*%d=%2d "...
2022-12-06
2
1429
【C】#KiKi求质数个数#
#include <stdio.h> #include <math.h> int main() { int cnt = 0; for (int i = 101; i <= 999; i += 2) { int flag = 1; ...
2022-12-06
1
1454
【C】#奇偶统计#
#include <stdio.h> int main() { int n, odd = 0, even = 0; scanf("%d", &n); for(int i = 1; i <= n; i++){ if(i % 2) ...
2022-12-05
1
1594
首页
上一页
1
2
3
4
5
6
7
8
9
10
下一页
末页