whilewhilewhile,这个代码短,但是效率低一点,while还不熟练哈哈 摘要:解题思路:swap转换注意事项:参考代码:#include<stdio.h> int main() { int m, n, x; scanf("%d %d %d", &m, &n…… 题解列表 2023年01月19日 0 点赞 0 评论 471 浏览 评分:0.0
挺有趣的哈哈这题目,这个代码有详细解读代码长 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int m,M,n,x,i; scanf("%d %d %d",&M,&n,&x); //M为最大体力值,n为…… 题解列表 2023年01月19日 0 点赞 0 评论 559 浏览 评分:0.0
想了半天正确的while,纪念一下 摘要:解题思路:注意事项:参考代码:#include <stdio.h>int main(){ int n,i; float a,sum; while(scanf("%d",&n)!=EO…… 题解列表 2023年01月19日 0 点赞 0 评论 467 浏览 评分:0.0
绕了好久,用数组方便,还是离不开for,累了哈哈 摘要:解题思路:建议用flag语句做判断,数组1、0开关注意事项:参考代码:#include<stdio.h>#define maxSize 50001int main(){ int arr[maxSize…… 题解列表 2023年01月19日 0 点赞 0 评论 627 浏览 评分:0.0
感觉不断练习除余数得到单数的方法 摘要:解题思路:if判断条件语句注意事项:else的细心参考代码:#include<stdio.h>int main(){ int n,k; int num=0; scanf("%d %d…… 题解列表 2023年01月19日 0 点赞 0 评论 565 浏览 评分:0.0
思路清晰版本,不懂就进来 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<math.h>int main(){int i,sum,t,k;int j=9;j=5*pow(j,5);//最大的数…… 题解列表 2023年01月19日 0 点赞 0 评论 574 浏览 评分:0.0
看到那么多字就头晕,细下心来读出数学公式即可 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int n; int a[100][2]; //定义个二维数组,存放每组数据 scanf("…… 题解列表 2023年01月19日 0 点赞 0 评论 499 浏览 评分:0.0
2099: C++重载练习之复数加减法 摘要:解题思路:当复数为0时不进行打印操作,注意正负号。参考代码:#include <iostream> #include <cmath> using namespace std; int m…… 题解列表 2023年01月19日 0 点赞 0 评论 1256 浏览 评分:9.9
顺序查找之谁拿了最多奖学金 ```c#includeintmain(){charname[100][21],ganbu[100],xibu[100];intnum,qimo[100],banji[100],lunwen[100],sum[100]={0},max=0,maxname,sumsum=0;//sum数组必须初始化, 题解列表 2023年01月19日 0 点赞 0 评论 654 浏览 评分:9.9
喜欢简单的可以看一下 摘要:解题思路:注意事项:count一定要初始化为0,而且数字字符记得带单引号参考代码:#include<stdio.h>int main(){char str[255];int i,count=0;get…… 题解列表 2023年01月19日 0 点赞 0 评论 607 浏览 评分:0.0