comp.lang.ada
 help / color / mirror / Atom feed
From: concert!news-feed-1.peachnet.edu!umn.edu!csus.edu!netcom.com!netcomsv!nit elog!michael.hagerty@gatech.edu  (Michael Hagerty)
Subject: PRECEDENCE RULES (WAS
Date: 1 Jul 93 23:05:00 GMT	[thread overview]
Message-ID: <2011.237.uupcb@nitelog.com> (raw)

On 29 Jun 93, Richard A. O'keefe posted to All:

RO. The Pascal standard (IOS/EIC 7185:1990) says that
  . (i mod j) is an error if j <= 0.  That surprised me, I hadn't realised
  . that it was defined for i < 0.  It goes on to point out explicitly
  . "Only for i >= 0 and j > 0 does the relation (i div j)*j + i mod j = i
  . hold." _That_ stunned me.  i div j and i mod j both defined for negative i,
  . but not compatibly?

As a former member of the Joint Pascal Committee who attended the meeting 
where the rule regarding mod was voted upon, I remember a very long and
heated discussion over the relative merits of three different positions.
The first was what was called the "FORTRAN rule", the second was the position
favored by mathematicians, while the third was the inconsistent one finally
selected.  Alas, I was in the minority.

The meeting was held in a conference room at the University of Colorado's
computer center.  Many of us found it more enjoyable to go outside of the
room and help students correct their Pascal programs than to sit in the room
and listen to this jibberish...

Regards, Mikey <michael.hagerty@nitelog.com>
---
 . MR/2 1.51 #63 . This is your brain.  Postscript on brain your is This.
                                                       

                 reply	other threads:[~1993-07-01 23:05 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox