Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
用Hash过的是用什么Hash函数,说下我死活过不了,只好二分水过 int temp=0; int v=abs(a),u=abs(b); temp=((temp<<2)+(l>>4))^(l<<10); temp=((temp<<2)+(x>>4))^(x<<10); temp=((temp<<2)+(y>>4))^(y<<10); int temp2=temp; temp=((temp<<2)+(u>>4))^(u<<10); //自己对应的Hash temp=((temp<<2)+(v>>4))^(v<<10); temp2=((temp2<<2)+(v>>4))^(v<<10); //垂直对应的Hash temp2=((temp2<<2)+(u>>4))^(u<<10); 这个折叠还不高效? Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator