[vox-tech] loop never exits!

Brian Lavender brian at brie.com
Thu Apr 22 09:15:10 PDT 2010


On Thu, Apr 22, 2010 at 09:03:23AM -0500, Chanoch (Ken) Bloom wrote:
> 
> The following idiom must be used instead:
> 
> int* iterator=thearray+itssize;
> while( iterator-- > thearray){
>   /* do something with the iterator. */
> }
> 

Very nice. If we had a "Hoare" karma point, I would definitely
think that this deserves one. 

Trivia question. 

What is the link between Charles Hoare and Bertrand Meyer?

brian
-- 
Brian Lavender
http://www.brie.com/brian/

"There are two ways of constructing a software design. One way is to
make it so simple that there are obviously no deficiencies. And the other
way is to make it so complicated that there are no obvious deficiencies."

Professor C. A. R. Hoare
The 1980 Turing award lecture


More information about the vox-tech mailing list