Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 ggr 10/10/85; site bentley.UUCP Path: utzoo!watmath!clyde!cbosgd!ihnp4!bentley!kwh From: kwh@bentley.UUCP (KW Heuer) Newsgroups: net.lang.c++ Subject: Re: Unintuitive semantics for initializing in for statements Message-ID: <738@bentley.UUCP> Date: Wed, 23-Apr-86 12:47:09 EST Article-I.D.: bentley.738 Posted: Wed Apr 23 12:47:09 1986 Date-Received: Thu, 24-Apr-86 07:42:13 EST References: <5334@alice.uUCp> Organization: AT&T Bell Laboratories, Liberty Corner Lines: 29 In article <5334@alice.uUCp> alice!shopiro (Jonathan Shopiro) writes: >The advantage in having the iteration variable declared in a for >statement remain accessible is that you can test its value after >the end of the loop. True, although I seldom (if ever) use it -- if it was a simple counting loop as in the example, I already know the terminating value unless a break statement was reached ("for (i=0; i