Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.PCS 1/10/84; site ahuta.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!ihnp4!houxm!ahuta!rkl From: rkl@ahuta.UUCP (k.laux) Newsgroups: net.lang.c Subject: Re: Quiz for Novice to Intermediate C Users Message-ID: <623@ahuta.UUCP> Date: Thu, 18-Apr-85 12:19:19 EST Article-I.D.: ahuta.623 Posted: Thu Apr 18 12:19:19 1985 Date-Received: Fri, 19-Apr-85 00:36:48 EST References: <646@dataio.UUCP> Organization: AT&T Information Systems Labs, Holmdel NJ Lines: 15 REFERENCES: <646@dataio.UUCP> Pretty slick, although misleading. This little program most graphically demonstrates that one should ALWAYS PUT SPACES AROUND OPERATORS. BTW, the answer is that foo prints 10 because the '/*' in 'a=b/*p;' is interpreted as the start of a comment; the preprocessor is the culprit because it looks for comments to strip them out before the compilation phase (ie order of precedence does not apply). R. Kevin Laux Software Vendor Tech Support ATTIS Lincroft ahuta!rkl