题解 2042: 杨辉三角 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;typedef long long ll;const ll N =1e3;ll a…… 题解列表 2024年05月26日 0 点赞 0 评论 193 浏览 评分:0.0
编写题解 2818: 分离整数的各个数位 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){long long a; cin>>a;while(a){co…… 题解列表 2024年05月26日 0 点赞 0 评论 224 浏览 评分:0.0
编写题解 2820: 含k个3的数 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int jgs(int n) { int j=0;while(n){if(n%10=…… 题解列表 2024年05月26日 0 点赞 0 评论 143 浏览 评分:0.0
编写题解 1022: [编程入门]筛选N以内的素数 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;bool ss(int n) { for(int i=2;i<n;i++) { …… 题解列表 2024年05月26日 0 点赞 0 评论 152 浏览 评分:0.0
编写题解 2828: 与7无关的数 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;bool bsq(int n) { for(int i=1;i<=n;i++) { …… 题解列表 2024年05月26日 0 点赞 0 评论 119 浏览 评分:0.0
辗转相除法(c语言) 摘要:解题思路:辗转相除法通过除数与余数之间不断求余,直到为零,最后的的余数就为最大公因数。注意事项:return (m%n==0)?n:gcd(n,m%n);这一段代码就已经实现了两个数的大小判断。参考代…… 题解列表 2024年05月26日 0 点赞 0 评论 301 浏览 评分:0.0
鸡兔同笼问题(C语言) 摘要:解题思路:注意事项:无解的情况为结果小于零或者不为整数参考代码:#include <stdio.h>int main(){ int a,b; while(scanf("%d %d",&a,&b)…… 题解列表 2024年05月27日 0 点赞 0 评论 203 浏览 评分:0.0
编写题解 2823: 计算分数加减表达式的值 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){int n;double s=0;cin>>n;for(int…… 题解列表 2024年05月27日 0 点赞 0 评论 148 浏览 评分:0.0
1073弟弟的作业(scanf函数的粗略解读) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a,b,c; int sum=0; char fuhao; //scanf函数是有返回值的 //返回 -…… 题解列表 2024年05月27日 0 点赞 0 评论 216 浏览 评分:0.0
for循环统计(c语言) 摘要:解题思路:注意事项:如果不是if{}else if{}的形式,内存会过大。参考代码:#include #include int main(void) { char str[200]; …… 题解列表 2024年05月27日 0 点赞 0 评论 602 浏览 评分:0.0