C bites / programming style

Ed Nather nather at utastro.UUCP
Tue Sep 10 09:36:20 AEST 1985


> I prefer:
> 
> 	if(some condition) {
> 		A statement;
> 		Another Statement;
> 		Some Garbage;
> 		}
> 	while(another condition) {
> 		etc;
> 		etc;
> 		}
>   Dave Bloom

That's also the style I use, except that I set the tabs every 4 spaces so
several indents will still show on the page.  I tried several styles
(K&R, separate lines for each brace, etc) and finally settled on this one.
I'm happy with it and find it very easy to follow.

Gad, Dave ... I might even be able to read *your* code!

-- 
Ed Nather
Astronomy Dept, U of Texas @ Austin
{allegra,ihnp4}!{noao,ut-sally}!utastro!nather
nather at astro.UTEXAS.EDU



More information about the Comp.lang.c mailing list