Seikimatsu Occult Tonneru Time Limit: 6000ms Memory Limit: 32768KB This problem will be judged on HDU. Original ID: 430964-bit integer IO format: %I64d Java class name: Main During the world war, to avoid the upcoming Carpet-bombing from The T…
题意:输入 n 个城市 m 条边,但是边有三种有向边 a b c d,第一种是 d 是 0,那么就是一条普通的路,可以通过无穷多人,如果 d < 0,那么就是隧道,这个隧道是可以藏 c 个人,当然也是通过无穷多人的,如果 d > 0,那么这是一座桥,第一次可以通过一个人,如果修复的话,就可以通过无穷多人,问你最多藏的人数,还有最少花费. 析:只是这样是不能做的,但是题目说了桥不超过 12 个,说实话这个条件太隐蔽了,就是不想让人发现,可惜的是队友没读出来,我也实在是没想出来怎么做,后来一查题…
Seikimatsu Occult Tonneru Time Limit: 12000/6000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 1741 Accepted Submission(s): 438 Problem Description During the world war, to avoid the upcoming Carpet-bombing fro…
Saving HDU Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 7194 Accepted Submission(s): 3345 Problem Description 话说上回讲到海东集团面临内外交困,公司的元老也只剩下XHD夫妇二人了.显然,作为多年拼搏的商人,XHD不会坐以待毙的. 一天,当他正在苦思冥想解困良策的…
http://acm.hdu.edu.cn/showproblem.php?pid=3037 Lucas定理模板. 现在才写,noip滚粗前兆QAQ #include<cstdio> #include<cstring> #include<algorithm> using namespace std; typedef long long ll; int jc[100003]; int p; int ipow(int x, int b) { ll t = 1, w = x;…