[HELP] num_hash problem
#1

I want to transform this to PHP.

anyone can help-me ?

pawn Код:
stock num_hash(buf[])
 {
    new length=strlen(buf);
    new s1 = 1;
    new s2 = 0;
    new n;
    for (n=0; n<length; n++) {
       s1 = (s1 + buf[n]) % 65521;
       s2 = (s2 + s1)     % 65521;
    }
    return (s2 << 16) + s1;
 }
Reply


Messages In This Thread
[HELP] num_hash problem - by Ricop522 - 24.06.2011, 17:21
Re: [HELP] num_hash problem - by rjjj - 24.06.2011, 18:38

Forum Jump:


Users browsing this thread: 1 Guest(s)