明天就NOIP了..
今天找到一堆常用的字符串Hash算法.贴出来分享+以后自己找也方便..
RS Hash:

function RSHash(S: string): Cardinal;
var
a, b: Cardinal;
I: Integer;
begin, ,