Re: How do you check the equivalency of references?
Re: How do you check the equivalency of references?
- Subject: Re: How do you check the equivalency of references?
- From: John W Baxter <email@hidden>
- Date: Thu, 9 Aug 2001 22:45:09 -0700
At 17:59 -0400 8/9/01, Arthur J Knapp wrote:
>
From the Useless AppleScript Library:
>
>
(* A "universal" hash function for strings.
>
*)
>
on hash(str, max)
>
set {a, b, h} to {31415, 27183, 0}
>
repeat with c in str
>
set h to (a * h + (ASCII number c)) mod max
>
end repeat
>
return h
>
end hash
Hmmm...what does b do in there (aside from separating a and h)? ;-)
I have a hunch we're missing something. --John
--
John Baxter email@hidden Port Ludlow, WA, USA