Xref: utzoo comp.theory:368 comp.misc:8273 comp.lang.misc:4204 Path: utzoo!attcan!uunet!husc6!spdcc!merk!alliant!linus!bs From: bs@linus.UUCP (Robert D. Silverman) Newsgroups: comp.theory,comp.misc,comp.lang.misc Subject: Re: Modulus (Re: hashing function for strings) Message-ID: <98399@linus.UUCP> Date: 22 Feb 90 15:27:32 GMT References: <12099@goofy.megatest.UUCP> Reply-To: bs@linus.UUCP (Robert D. Silverman) Organization: The MITRE Corporation, Bedford MA Lines: 28 In article <12099@goofy.megatest.UUCP> djones@megatest.UUCP (Dave Jones) writes: :From article , by flee@shire.cs.psu.edu (Felix Lee): :> Dave Jones wrote: :>>I differ. The first of these, -5 div 3 == -1 is wrong. :> :> The contrary view is that abs(a/b) != abs(-a/b) is strange. It :> depends on what you're doing. I have no problems with either stance. : Sigh. Don't people learn about functions in school anymore? The mapping 5 div 3 -- > 1 is a function. It is the floor function of the quotient. Why on earth SHOULD one expect that for some function f abs(f(a,b)) = abs(f(-a,b))????? It would be the same as expecting f(a,b) = -f(-a,b). This simply is not true of all functions. It is not strange. It is simply people who know very little mathematics shooting their mouth off. -- Bob Silverman #include Internet: bs@linus.mitre.org; UUCP: {decvax,philabs}!linus!bs Mitre Corporation, Bedford, MA 01730