Hifipsysta-1165-明明的随机数(C++代码)基于STL的实现,我敢说这是本题最简单的代码 摘要: ```cpp #include #include using namespace std; int main(){ int n,tmp; scanf("%d", &…… 题解列表 2022年02月07日 0 点赞 0 评论 372 浏览 评分:0.0
1234: 检查一个数是否为质数 摘要:解题思路:注意事项:参考代码:n=int(input()) s=0 for i in range(2,n//2+1): if n%i==0: print('N…… 题解列表 2022年02月07日 0 点赞 0 评论 406 浏览 评分:0.0
1259: 送分题素数 摘要:解题思路:注意事项:参考代码:def get(n): s=0 for i in range(2,n//2+1): if n%i==0:   题解列表 2022年02月07日 0 点赞 0 评论 336 浏览 评分:0.0
Hifipsysta-1207-字符排列问题(C++代码)看到大家方法这么复杂,我写了个非常简单的STL实现 摘要:##### 基本思路: ① 将字符串读入数组存储 ② 采用sort函数以字典序排序 ③ 采用next_permutation输出全排列,每迭代依次采用cnt记数 ##### 注意事项: …… 题解列表 2022年02月07日 0 点赞 0 评论 373 浏览 评分:0.0
明明白白的 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ long int n; while (scanf("%d", &n) != EOF) { long int s…… 题解列表 2022年02月07日 0 点赞 0 评论 344 浏览 评分:0.0
Hifipsysta-1976-蓝桥杯算法提高VIP-删除重复元素(C++代码)频数统计法,扫描两遍就出来了 摘要:```cpp #include #include using namespace std; const int MAXN=128; int table[MAXN]; int mai…… 题解列表 2022年02月07日 0 点赞 0 评论 396 浏览 评分:0.0
【C语言】简单的输出 摘要:解题思路: 直接按照题目需求输出就行了 不过有一个需要注意的地方:就是数字之前除了占位符的空隙外,还有一个空格参考代码: 简单的输出:#include<stdio.h…… 题解列表 2022年02月07日 0 点赞 0 评论 324 浏览 评分:0.0
【C语言】简单的排序问题 摘要:解题思路: 这题考察的就是排序问题,不过这里的排序对象变成了字符串 所以我们要使用 strcmp(str1,str2); 如果str1 > str2 则函数返回 > 0 的值…… 题解列表 2022年02月07日 0 点赞 0 评论 381 浏览 评分:0.0
编写题解 1011: [编程入门]最大公约数与最小公倍数 摘要:解题思路:其中有为最大公因数,最小公倍数的先讨论;eg 6 2然后是找最小数的因数再找共同的因数注意事项:参考代码:def f(a,b): yinshu=[] gys=[] q=0 …… 题解列表 2022年02月07日 0 点赞 0 评论 397 浏览 评分:0.0
Hifipsysta-1096-Minesweeper(C++代码)空间搜索法 摘要:```cpp #include using namespace std; const int MAXN=100; struct node{ int x; int y…… 题解列表 2022年02月07日 0 点赞 0 评论 426 浏览 评分:0.0