Path: utzoo!attcan!uunet!mcvax!ukc!mupsy!mucs!ian From: ian@ux.cs.man.ac.uk (Ian Cottam) Newsgroups: comp.lang.misc Subject: ALGOL 68 (skip) Message-ID: <5193@ux.cs.man.ac.uk> Date: 30 Nov 88 15:37:08 GMT Organization: Computer Science, University of Manchester, UK Lines: 30 In article <594@tuck.nott-cs.UUCP> anw@maths.nott.ac.uk (Dr A. N. Walker) writes: >[Clay Phipps (>>) and Steven Ryan (>) are surprised that: > >> begin int I := 0, K := 1; > >> ref int Ptr := I; > >> Ptr := K; > >> Print (I); > >> end >prints 0 rather than 1.] Charles Lindsey replies... Various people have been trying to explain this one. Personally, I would write it as follows. begin loc int I := 0, K := 1; loc ref int Ptr := I; Ptr := K; Print (I); end Me: Actually Charles would not write it like that as it (really the original version) is not syntactically correct. ----------------------------------------------------------------- Ian Cottam, Room IT101, Department of Computer Science, University of Manchester, Oxford Road, Manchester, M13 9PL, U.K. Tel: (+44) 61-275 6157 FAX: (+44) 61-275-6280 ARPA: ian%ux.cs.man.ac.uk@nss.cs.ucl.ac.uk JANET: ian@uk.ac.man.cs.ux UUCP: ..!mcvax!ukc!mur7!ian -----------------------------------------------------------------