摘要: 题目链接很难想。会哈希,但是想不出。需要一个转化,本来是求某一段上的二进制上每一位的1数目相等,转化为找两段相等的,换元可推出公式。最后注意特判。。 1 #include <iostream> 2 #include <cstdio> 3 #include <cstring> 4 #include <string> 5 using namespace std; 6 #define MOD 97777 7 struct node 8 { 9 int data;10 struct node *next;11 }*head[MOD],hash[60000 阅读全文
posted @ 2013-01-14 19:09 Naix_x 阅读(161) 评论(0) 推荐(0) 编辑