Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!cs.utexas.edu!yale!cmcl2!kramden.acf.nyu.edu!brnstnd From: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) Newsgroups: comp.lang.c Subject: Re: a style question Message-ID: <12683:Oct102:57:1590@kramden.acf.nyu.edu> Date: 1 Oct 90 02:57:15 GMT References: <7341@darkstar.ucsc.edu> <8660@ncar.ucar.edu> Organization: IR Lines: 9 In article <8660@ncar.ucar.edu> steve@groucho.ucar.edu (Steve Emmerson) writes: > # define NUM_ELEMENTS 100 > for (x = 0; x < NUM_ELEMENTS; x++) ... Hmmm. I'll automatically write x = NUM_ELEMENTS; while (x--) ... for this kind of loop. On many computers it'll run noticeably faster, and I can safely replace NUM_ELEMENTS by a function call. ---Dan