home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c
- Path: sparky!uunet!psinntp!ptsys1!mliu
- From: mliu@pt.com (Fred Liu)
- Subject: Re: C code Layout
- Message-ID: <1992Dec24.142340.6500@pt.com>
- Organization: Performance Technologies, Incorporated
- References: <771@ulogic.UUCP> <1992Dec23.153137.13423@fcom.cc.utah.edu> <BzqIHE.7p3@rahul.net>
- Distribution: usa
- Date: Thu, 24 Dec 1992 14:23:40 GMT
- Lines: 31
-
- In article <BzqIHE.7p3@rahul.net> kpapai@rahul.net (Ken Papai) writes:
- >nmp@mfltd.co.uk (Nic Percival (x5336)) writes:
- >
- >and I like style C format too:
- >
- > if (editor == BRIEF)
- > {
- > printf( "You are a lucky software engineer.\n" );
- > printf( "You will be rewarded handsomely because you are so
- > productive!")
- > }
-
- I can agree with this, although I don't use this style.
-
- > else
- > printf( "You are an unlucky VI or EMACS user. Sorry..." );
-
- I don't like this. I always rather use
-
- > else {
- > printf( "You are an unlucky VI or EMACS user. Sorry..." );
- }
-
- In my C programming practice, "if ()" and "} else ()" are always
- followed by {. It allows me to insert and delete printfs inside a
- if with least bothering to other code, and it does not take to much
- time and space to do that.
-
- --
- Fred Liu, Performance Technologies Incorporated mliu@pt.com
- 315 Science Parkway, Rochester, New York 14620 uupsi!ptsys1!mliu
-