Regarding coding style
Steven D'Aprano
steve at REMOVE-THIS-cybersource.com.au
Fri Mar 7 23:38:41 EST 2008
On Fri, 07 Mar 2008 20:04:47 -0800, dave_mikesell wrote:
> On Mar 7, 10:31 am, "K Viltersten" <t... at viltersten.com> wrote:
>> I've been recommended reading
>> of:http://www.python.org/dev/peps/pep-0008/ and in there i saw two
>> things that i
>> need to get elaborated.
>>
>> 1. When writing English, Strunk and
>> White apply.
>
> If your code needs so much descriptive prose that you have to consult
> Strunk and White, refactor it to be more clear. Excessive comments are
> the hobgoblin of overly complex and/or sloppy code.
Nonsense. Poor English is poor English whether you're writing short one-
line comments or three hundred page manuals.
store = make_store()
x = get_stuff(store) # Get the stuff what was brought at the store.
Not that I would consider S & W the best source for good grammar or style.
--
Steven
More information about the Python-list
mailing list