
ccf
圆滚滚的柴柴
这个作者很懒,什么都没留下…
展开
-
201712-1
#include<stdio.h>#include<stdlib.h>#include<math.h>int HaveSame(int a[],int n){ int i = 0; int result=20000; for (i = 1; i < n; i++) { if (a[i] == a[i...原创 2018-03-12 13:07:30 · 170 阅读 · 0 评论 -
201712-2
超时,得了90分。#include<stdio.h>#include<stdlib.h>#include<math.h>int islast(int a[], int n, int *result){ int sum = 0; for (int i = 1; i <= n; i++) { if (a...原创 2018-03-12 13:56:47 · 170 阅读 · 0 评论 -
弗洛伊德
ccf201712-4,赋权图的变种,没想明白,只写了 弗洛伊德算法,得了30分。#include<stdio.h>#include<stdlib.h>#include<math.h>int matrice[520][520];int path[520][520];int dis[520];int main(){ int n, m...原创 2018-03-13 13:34:00 · 342 阅读 · 0 评论 -
201709-1打酱油
贪心算法。#include<stdio.h>int getmax(int n){ int result = 0; if (n / 50) { result+= ((n / 50) * 7); n %= 50; } if (n / 30) { result += ((n / 30)...原创 2018-03-13 14:07:27 · 206 阅读 · 0 评论