2012年8月7日

hdu 1873 看病要排队

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1873两种自定义优先级写法View Code 1 #include<iostream> 2 #include<queue> 3 #include<string> 4 using namespace std; 5 struct Node 6 { 7 int time; 8 int import; 9 bool operator<(const Node &a) const10 {11 if(a.import>import) return true;12 .. 阅读全文

posted @ 2012-08-07 13:55 仁者无敌8勇者无惧 阅读(241) 评论(0) 推荐(0) 编辑

自定义优先级

摘要: #include<iostream>#include<queue>#include<string>using namespace std;struct Node{ string name; int score; bool operator<(const Node &a) const { return a.score<score; }};int main(){ priority_queue<Node> ss; Node node; node.name="aaa"; node.score=90; ss.push 阅读全文

posted @ 2012-08-07 13:17 仁者无敌8勇者无惧 阅读(234) 评论(0) 推荐(0) 编辑

hdu 1263水果

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1263水果Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 1528Accepted Submission(s): 608Problem Description夏天来了~~好开心啊,呵呵,好多好多水果~~Joe经营着一个不大的水果店.他认为生存之道就是经营最受顾客欢迎的水果.现在他想要一份水果销售情况的明细表,这样Joe就可以很容易掌握所有水果的销售情况了.In 阅读全文

posted @ 2012-08-07 12:08 仁者无敌8勇者无惧 阅读(1266) 评论(0) 推荐(0) 编辑

导航