成绩排序(答案错误只有50分的试试把name数组空间改为101) 参考代码:```c#include#includestructstudent{charname[101];//字符串后面要有个空intage;intscore;};voidswap(structstudent*a,structstudent*b)//交换{structstudentt;t=*a;*a= 题解列表 2023年11月15日 1 点赞 1 评论 470 浏览 评分:10.0
[编程入门]最大公约数与最小公倍数(C语言) 摘要:解题思路:注意事项:参考代码:方法一:#include<stdio.h>int main(){ int m,n,a,b; scanf("%d %d",&m,&n); a=m; …… 题解列表 2023年11月15日 0 点赞 0 评论 457 浏览 评分:0.0
字符排序(冒泡排序) 摘要:解题思路:注意事项:参考代码:#include <stdio.h> #include <string.h> // 定义一个函数place,用于对输入的字符串按ASCII码从小到大进行冒泡排序 …… 题解列表 2023年11月14日 0 点赞 0 评论 737 浏览 评分:9.9
最简单易懂,看不懂你来打我! 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int m,n,min,max; int x,y; scanf("%d%d",&m,&n); i…… 题解列表 2023年11月14日 0 点赞 0 评论 443 浏览 评分:0.0
c语言代码解决问题 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<stdlib.h>#define N 202#define M 5002int dp[N][M];int weight…… 题解列表 2023年11月14日 0 点赞 0 评论 773 浏览 评分:0.0
十五行精简代码,强迫症福利! 摘要:解题思路:首先最大公因数,可以使用阿基米德留下的智慧,a和b的最大公因数就是a和a%b的最大公因数,易得之。而最大公倍数是a*b除以最大公因数。证明:令最大公倍数=a*b×k分之一,k>=1,且a/k…… 题解列表 2023年11月14日 0 点赞 0 评论 553 浏览 评分:9.9
c代码记录之角谷猜想-C 摘要:解题思路:注意事项:参考代码:#include<stdio.h> int deal(int m){ if(m%2==0){ printf("%d/2=%d\n",m,…… 题解列表 2023年11月14日 0 点赞 0 评论 441 浏览 评分:0.0
c代码记录之最大数问题 摘要:解题思路:注意事项:-1仅标记输入结束,不参与比较参考代码:#include<stdio.h> #include<stdlib.h> int main(){ int *num; …… 题解列表 2023年11月14日 0 点赞 0 评论 451 浏览 评分:0.0
c代码记录之报数问题 摘要:解题思路:创建一个数组盛放报数人序号,报完数后未被pass的人,其序号被扩充到数组结尾等待下次报数注意事项:参考代码:#include<stdio.h> #include<stdlib.h> …… 题解列表 2023年11月14日 0 点赞 0 评论 436 浏览 评分:0.0
c代码记录之n个数的排序 摘要:解题思路:选择排序法注意事项:参考代码:直接输入一组数进行排序#include<stdio.h> #include<stdlib.h> //创建函数用于数组排序 void sort(in…… 题解列表 2023年11月14日 0 点赞 0 评论 420 浏览 评分:0.0