随笔分类 -  搜索

摘要:void dfs(int tmp[],int deep)//deep表示当前深度,temp_deep表示当前限定的最大深度,超过该深度,则不必继续下去 { if(flag) return; if(deep+8-check(tmp)>tmp_deep)//检查当前方案是否还有必要继续下去 return; if(check(tmp)==8)... 阅读全文
posted @ 2016-08-08 14:26 相儒以沫 阅读(219) 评论(0) 推荐(0)
摘要:#include #include #include #include #include using namespace std; const int INF=1e9; struct node { int to,w,next; }edge1[500010]; node edge2[500010]; struct A { int f,g,v; boo... 阅读全文
posted @ 2016-08-08 14:22 相儒以沫 阅读(199) 评论(0) 推荐(0)
摘要:1 #include 2 #include 3 #include 4 #include 5 6 using namespace std; 7 8 int n; 9 int stick[70];10 bool mark[70];11 int sum;12 int len;13 int n... 阅读全文
posted @ 2015-08-21 11:03 相儒以沫 阅读(141) 评论(0) 推荐(0)
摘要:1 #include 2 #include 3 #include 4 #include 5 #include 6 #include 7 #include 8 9 using namespace std; 10 11 char arr[2][15][15]; 12... 阅读全文
posted @ 2015-08-19 13:57 相儒以沫 阅读(112) 评论(0) 推荐(0)
摘要:1 #include 2 #include 3 #include 4 #include 5 6 using namespace std; 7 8 map >mp; 9 queue q;10 11 int main()12 {13 int x0,y0,x1,y1,n;14 ... 阅读全文
posted @ 2015-08-19 10:39 相儒以沫 阅读(197) 评论(0) 推荐(0)