摘要: 2019-11-30 思路很简单 注意那个找最大值,排序太费时间。学会了qsort😊 #include <stdio.h> #include <stdlib.h> #define N 1000005 int cycleLength[N]; int getCycleLength(int n) { i 阅读全文
posted @ 2019-12-01 18:33 今天你AC了吗 阅读(118) 评论(0) 推荐(0) 编辑
摘要: #include <stdio.h> #include <stdlib.h> #define MAX_NUM 3 int findPosSE(int n) { int meatBalls[n]; int sum = 0; int i; for (i=0; i<n; i++) { scanf("%d" 阅读全文
posted @ 2019-12-01 18:32 今天你AC了吗 阅读(119) 评论(0) 推荐(0) 编辑
摘要: 2019-11-29 1046 梳理好思路再开始写 注意逻辑问题 调用函数:遍历一遍找最小的。方法有很多种,想出最顺的✍ #include <stdio.h> #include <stdlib.h> int find_min(int map[16][3],int r,int g,int b) { i 阅读全文
posted @ 2019-12-01 18:31 今天你AC了吗 阅读(135) 评论(0) 推荐(0) 编辑
摘要: 2019-11-30 1118( 动态分配二维数组/结构体)给出来的是坐标,判断共线(斜率) #include <stdio.h> #include <stdlib.h> #define N 700 int main() { int n,i,j; struct { int x,y; } p[N]; 阅读全文
posted @ 2019-12-01 18:31 今天你AC了吗 阅读(184) 评论(0) 推荐(0) 编辑
摘要: 2019-11-28 1004 %. 2f自动四舍五入 #include <stdio.h> #include <stdlib.h> int main() { int i; double money[12]; double average,sum=0; for(i=0;i<12;i++) { sca 阅读全文
posted @ 2019-12-01 18:30 今天你AC了吗 阅读(131) 评论(0) 推荐(0) 编辑
摘要: 2019-11-29 1005 要认真审题 读明白题意 知道题目是干嘛的 #include <stdio.h> #include <stdlib.h> int main() { int n; double x,y,s,pi=3.141592654; int year,i=0; scanf("%d", 阅读全文
posted @ 2019-12-01 18:30 今天你AC了吗 阅读(73) 评论(0) 推荐(0) 编辑
摘要: 2019-11-29 1007 刚学的结构体,多用。🌂个循环:1计算逆序 2冒泡排序 3输出 #include <stdio.h> #include <stdlib.h> #include <string.h> #define M 200 struct dna { char str[M]; int 阅读全文
posted @ 2019-12-01 18:30 今天你AC了吗 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 2019-11-28 1003 简化代码,也别把问题想复杂 #include <stdio.h> #include <stdlib.h> int main() { float c,sum,base; int count; scanf("%f",&c); while(c!=0.00) { base=2 阅读全文
posted @ 2019-12-01 18:29 今天你AC了吗 阅读(103) 评论(0) 推荐(0) 编辑
摘要: 2019-11-28 1000 努力锻炼编程能力 学习写出完美的代码 �� ! #include <stdio.h> #include <stdlib.h> int main() { int a,b; scanf("%d %d",&a, &b); printf("%d\n",a+b); return 阅读全文
posted @ 2019-12-01 18:28 今天你AC了吗 阅读(84) 评论(0) 推荐(0) 编辑