题解列表
2880: 计算鞍点
摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;long long a[100][100],n,sum=0;int main(){……
2880: 计算鞍点
摘要:解题思路:int main()
{
for(int i=1;i<=5;i++)//双重循环1
{
for(int j=1;j<=5;j++)//双重循环2
……
1852: 求1+2+3+...+n的值
摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;long long n,m,b,sum=0;long long gaosi(lon……
2955: 判决素数个数
摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;long long n,m,b,sum=0;int pdsushu(int x){……
用 for(auto & c:s)遍历字符串并赋值
摘要:解题思路: 字符串遍历注意事项: getline取空格参考代码:#include<iostream>#include<cstring>using na……
1199: 哥德巴赫曾猜测
摘要:解题思路:#include <bits/stdc++.h>using namespace std;int add(int n){ for(int i=2;i<n;i++) if(n……
使用for循环计算2的幂
摘要:因为懒得导入math.h库,就使用for循环写
```c
#include
int main()
{
int n,s=1,i;
scanf("%d",&n);
f……