home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / software / 4981 < prev    next >
Encoding:
Internet Message Format  |  1992-12-15  |  1.6 KB

  1. From: daves@hpopd.pwd.hp.com (Dave Straker)
  2. Date: Mon, 14 Dec 1992 17:43:44 GMT
  3. Subject: Re: C Code Layout
  4. Message-ID: <-191179986@hpopd.pwd.hp.com>
  5. Organization: Hewlett-Packard, CCSY Messaging Centre, UK.
  6. Path: sparky!uunet!spool.mu.edu!sdd.hp.com!hpscit.sc.hp.com!hplextra!otter.hpl.hp.com!hpopd!daves
  7. Newsgroups: comp.software-eng
  8. References: <1992Dec11.020200.944@seq.uncwil.edu>
  9. Lines: 30
  10.  
  11. > >
  12. > >On the subject of C CODE layout.
  13. > >I require my students to use the following format. 
  14. >    ^^^^^^^    ^^^^^^^^            ^^^^^^^^^^^^^^^^
  15. > Why in the world would you REQUIRE students to use a particular
  16. > coding style? Coding style is one of the things that makes each
  17. > programmer unique and lends some "art" to this thing we call
  18. > programming!
  19.  
  20. This highlights an interesting teaching dilemma. Do you enforce
  21. standards or allow individual style? Enforcing standards teaches
  22. something of the 'real world' where you may have to use standards
  23. that you don't 100% approve of. It also meets the objective of
  24. easing communications about programs between lecturer and student
  25. (and maybe even student and student). On the other hand, there
  26. is no 'right' style and it may be wrong to 'lock' students into
  27. a single style where they may later be required to use other styles.
  28.  
  29. On balance, I'd probably do a bit of both. I'd also get students
  30. to mark one another's work for both, thus saving a bit of lecturer's
  31. effort whilst simultaneously letting them find out the value of
  32. using a style with which other people are familiar.
  33.  
  34.  
  35. Dave Straker
  36.  
  37. plug:
  38. (Author of 'C Style: Standards and Guidelines' Pub. Prentice Hall, 1992)
  39.  
  40.