Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #6359
| Path | csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!news.linkpendium.com!news.linkpendium.com!news.snarked.org!newsfeed.news.ucla.edu!usenet.stanford.edu!news.kjsl.com!news.alt.net!news.astraweb.com!border6.newsrouter.astraweb.com!not-for-mail |
|---|---|
| From | Ben Finney <ben+python@benfinney.id.au> |
| Newsgroups | comp.lang.python |
| Subject | Re: The worth of comments |
| References | <mailman.8533.1306409304.9058.python-list@python.org> <mailman.2126.1306435826.9059.python-list@python.org> |
| X-Public-Key-ID | 0xAC128405 |
| X-Public-Key-Fingerprint | 517C F14B B2F3 98B0 CB35 4855 B8B2 4C06 AC12 8405 |
| X-Public-Key-URL | http://www.benfinney.id.au/contact/bfinney-pubkey.asc |
| X-Post-From | Ben Finney <bignose+hates-spam@benfinney.id.au> |
| Date | Fri, 27 May 2011 11:42:54 +1000 |
| Message-ID | <87sjs0apgh.fsf@benfinney.id.au> (permalink) |
| User-Agent | Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) |
| Cancel-Lock | sha1:3vcmBk3TjWFxUu/IRBoeXpGL7Xc= |
| MIME-Version | 1.0 |
| Content-Type | text/plain; charset=utf-8 |
| Content-Transfer-Encoding | 8bit |
| Lines | 26 |
| Organization | Unlimited download news at news.astraweb.com |
| NNTP-Posting-Host | eed2afb3.news.astraweb.com |
| X-Trace | DXC=flX24iBPPSm1m]JSMD?cjjL?0kYOcDh@j7^o:UA4R?ceS`HWH2Uf3?i]G;2>V^?kWcbEW9A[5UK?eNZ[SL`C\Kgc9n]_nU:hFYh |
| Xref | x330-a1.tempe.blueboxinc.net comp.lang.python:6359 |
Show key headers only | View raw
Richard Parker <r.richardparker@comcast.net> writes: > On May 26, 2011, at 4:28 AM, python-list-request@python.org wrote: > > > My experience is that comments in Python are of relatively low > > usefulness. (For avoidance of doubt: not *zero* usefulness, merely > > low.) I can name variables, functions and classes with sensible, > > self- documenting names. I am largely in agreement with this position (including the “not *zero* usefulness” caveat). > I'm less inclined to use comments on each line, or selected lines, but > rather use block comments instead. They require more thought and time > to write; however, the intended functionality of the code that follows > can be described in full. This I disagree with. If a section of code is interesting enough to deserve an explanation, then it is better to capture it in a helpfully-named function with its doc string having the explanation. -- \ “If this is your first visit to the USSR, you are welcome to | `\ it.” —hotel room, Moscow | _o__) | Ben Finney
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
The worth of comments Richard Parker <r.richardparker@comcast.net> - 2011-05-26 11:50 -0700
Re: The worth of comments Ben Finney <ben+python@benfinney.id.au> - 2011-05-27 11:42 +1000
Re: The worth of comments Grant Edwards <invalid@invalid.invalid> - 2011-05-27 13:54 +0000
Re: The worth of comments Irmen de Jong <irmen@-NOSPAM-xs4all.nl> - 2011-05-27 19:05 +0200
Re: The worth of comments Grant Edwards <invalid@invalid.invalid> - 2011-05-27 17:53 +0000
Re: The worth of comments Irmen de Jong <irmen.NOSPAM@xs4all.nl> - 2011-05-28 15:09 +0200
Re: The worth of comments python@bdurham.com - 2011-05-28 09:34 -0400
Re: The worth of comments Roy Smith <roy@panix.com> - 2011-05-28 09:36 -0400
Re: The worth of comments Chris Angelico <rosuav@gmail.com> - 2011-05-29 00:02 +1000
Re: The worth of comments Irmen de Jong <irmen.NOSPAM@xs4all.nl> - 2011-05-28 16:05 +0200
Re: The worth of comments Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2011-05-29 12:47 +1200
Re: The worth of comments Ben Finney <ben+python@benfinney.id.au> - 2011-05-29 11:41 +1000
Re: The worth of comments Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2011-05-29 23:05 +1200
Re: The worth of comments Grant Edwards <invalid@invalid.invalid> - 2011-05-29 14:43 +0000
Re: The worth of comments Roy Smith <roy@panix.com> - 2011-05-29 11:39 -0400
Re: The worth of comments Irmen de Jong <irmen.NOSPAM@xs4all.nl> - 2011-05-29 03:49 +0200
Re: The worth of comments Alister Ware <alister.ware@ntlworld.com> - 2011-05-29 17:26 +0000
Re: The worth of comments Neil Cerutti <neilc@norwich.edu> - 2011-05-31 14:47 +0000
Re: The worth of comments Roy Smith <roy@panix.com> - 2011-05-26 22:08 -0400
Re: The worth of comments Chris Angelico <rosuav@gmail.com> - 2011-05-27 15:13 +1000
Re: The worth of comments Roy Smith <roy@panix.com> - 2011-05-27 09:25 -0400
Re: The worth of comments Tim Roberts <timr@probo.com> - 2011-05-27 00:02 -0700
Re: The worth of comments "D'Arcy J.M. Cain" <darcy@druid.net> - 2011-05-27 09:29 -0400
RE: The worth of comments "Prasad, Ramit" <ramit.prasad@jpmchase.com> - 2011-05-27 14:17 -0400
csiph-web