摘要:
主要是51nod上的中位数(距离之和最小): 一:1096 距离之和最小: 是一道水题; #include<cstdio> #include<cstring> #include<algorithm> using std::sort; int map[10010]; int main() { int 阅读全文
摘要:
一:01背包 #include<cstdio> #include<algorithm> using namespace std; int m,t; int f[1001]; int w[1001],c[1001]; int main() { scanf("%d %d",&t,&m); for(int 阅读全文
摘要:
1589: [Usaco2008 Dec]Trick or Treat on the Farm 采集糖果 Description 每年万圣节,威斯康星的奶牛们都要打扮一番,出门在农场的N(1≤N≤100000)个牛棚里转悠,来采集糖果.她们每走到一个未曾经过的牛棚,就会采集这个棚里的1颗糖果. 农场 阅读全文
摘要:
D - Decrementing Time limit : 2sec / Memory limit : 256MB Score : 1000 points Problem Statement There are N integers written on a blackboard. The i-th 阅读全文