ACM->HDU
Fate_O
Lets go
展开
-
hdu4500 小Q系列故事——屌丝的逆袭
#include #include using namespace std; #define MAXN 100 + 10 const int INF = (~0U >> 1); int c[MAXN][MAXN]; int array[MAXN][MAXN]; int dir[4][2] = { 0, -1, -1, 0, 0, 1, 1, 0 }; void input()原创 2013-12-06 10:19:54 · 625 阅读 · 0 评论 -
hdu1536
#include #include #include #include using namespace std; #define MAXN 10000 + 10 const int INF = (~0U >> 1); int temp[MAXN], sg[MAXN]; void getsg() { sg[0] = 0; for (int i = 1; i <=原创 2013-12-06 10:47:41 · 490 阅读 · 0 评论 -
hdu1007最近点对
#include #include #include #include #include #include #include #include using namespace std; const int MAXN = 100000 + 10; const double inf = 1e100; struct Node { double x, y; }node[MAX原创 2013-12-07 19:52:43 · 539 阅读 · 0 评论 -
hdu1006
#include #include using namespace std; struct Segment { double l, r; }segment; double mabs(double x) { return x > 0 ? x : -x; } double d; Segment method(double a, double b) { Segmen原创 2013-12-07 12:04:00 · 502 阅读 · 0 评论 -
hdu1005
找周期 #include #include using namespace std; #define MAXN 100000 + 10 int f[MAXN]; void input() { int a, b, n; f[1] = 1; f[2] = 1; while (cin >> a >> b >> n, a || b || n)原创 2013-12-06 09:45:00 · 477 阅读 · 0 评论 -
hdu1848
sg函数#include #include using namespace std; #define MAXN 1000 + 10 int f[MAXN]; int sg[MAXN]; bool vis[MAXN]; void getsg() { sg[0] = 0; for (int i = 1; i <= 1000; i++) { mems原创 2013-12-06 09:46:06 · 624 阅读 · 0 评论