Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!ames!decwrl!uunet!modcomp!nigel From: nigel@modcomp.UUCP (Nigel Gamble) Newsgroups: comp.arch Subject: Re: Comparison operators (was: He's not the only one at it again!) Message-ID: <327@modcomp.UUCP> Date: 3 Aug 90 16:18:19 GMT References: <25681@cs.yale.edu> <9007301417.AA21099@thep.lu.se> <2377@crdos1.crd.ge.COM> Organization: MODCOMP, REAL/IX Development Group Lines: 18 davidsen@crdos1.crd.ge.COM (Wm E Davidsen Jr) writes: >In article <9007301417.AA21099@thep.lu.se> magnus@THEP.LU.SE (Magnus Olsson) writes: >| The people behind C *deliberately* changed the Algol operators >| '=' and ':=' to '==' and '=' to save keystrokes - in most programs, > But the change was made in B, not C, and just carried over. It may >well have been in BCPL, but I haven't written any in so long I'll have >to look it up. No, BCPL uses ':=' for assignment. It uses '=' for equality, but interestingly (to me, anyway) it uses neither '!=' nor '<>' for inequality. Instead, the compiler will accept either '~=' or '\=' as the inequality operator. The latter is suggestive of the mathematical symbol. -- Nigel Gamble uunet!modcomp!nigel MODCOMP, an AEG company modcomp!nigel@uunet.UU.NET 1650 W McNab Rd, Ft Lauderdale, FL 33340-6099