Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site watdaisy.UUCP Path: utzoo!watmath!watdaisy!gvcormack From: gvcormack@watdaisy.UUCP (Gordon V. Cormack) Newsgroups: net.lang Subject: Misleading COBOL semantics Message-ID: <6769@watdaisy.UUCP> Date: Tue, 27-Nov-84 10:24:36 EST Article-I.D.: watdaisy.6769 Posted: Tue Nov 27 10:24:36 1984 Date-Received: Wed, 28-Nov-84 03:28:34 EST Organization: U of Waterloo, Ontario Lines: 18 The recent discussion of IF A LESS THAN B OR C etc. reminds me of another case in which the semantics of COBOL are clearly not those implied by English interpretation. The statement MULTIPLY A BY B stores the result in B, not A as is implied. Therefore the following COBOL statement is invalid, even though it makes perfect sense. MULTIPLY MY-SALARY BY 2. In order to have the desired semantics, one must say: MULTIPLY 2 BY MY-SALARY. Gordon Cormack gvcormack@watdaisy.uucp gvcormack%watdasiy@waterloo.csnet