十里坡小白
十里坡小白
全部文章
分类
题解(7)
归档
标签
去牛客网
登录
/
注册
十里坡小白的博客
全部文章
(共7篇)
题解 | #[NOIP2013]记数问题#
#include <stdio.h> #include <math.h> //查找数字的个数 int SchNum(int num, int F) { int sum = 0; int rem = 0; int count = 0; int ...
C
2022-05-04
0
410
题解 | #[NOIP2015]金币#
#include <stdio.h> int main() { int num = 0; int day = 0; int count = 1; int sum = 0; scanf("%d", &day); for (int ...
C
2022-04-15
1
266
题解 | #数位之和#
#include <stdio.h> int main() { int num = 0; int sum = 0; while (scanf("%1d", &num) != EOF) { sum += num; } pri...
C
2022-04-11
0
321
题解 | #奇偶统计#
#include <stdio.h> int main() { int num = 0; scanf("%d", &num); printf("%d %d", (num + 1) / 2, num / 2); return 0; }
C
2022-04-10
0
325
题解 | #KiKi和酸奶#
//余数化一法 #include <stdio.h> int main() { int n, h, m; scanf("%d%d%d", &n, &h, &m); printf("%d\n", n - m / h - (m % h + 2)...
C
C++
2022-03-16
7
690
题解 | #2的n次方计算#
#include <stdio.h> int main() { int N; scanf("%d", &N); printf("%d\n", 1 << N); //数字是以二进制储存, N次方便向左移动N个二进制位 return 0; }
C
2022-03-14
1
516
题解 | #开学?#
#include <stdio.h> int main() { int Week, Day; scanf("%d%d", &Week, &Day); printf("%d\n",(Week + Day - 1) % 7 + 1); //避免出现周日余数为0,兼顾...
C
C++
2022-03-14
148
2307