On 26/04/2022 11.47, Rob Cliffe via Python-list wrote:
> Well, de gustibus non est disputandum. For me, the switch from the
> imperative mode to the descriptive mode produces a mild cognitive
> dissonance.
Disagree!
When coding, to whom?what are you talking?
When writing documentation - same qu
Well, de gustibus non est disputandum. For me, the switch from the
imperative mode to the descriptive mode produces a mild cognitive
dissonance.
Best wishes
Rob Cliffe
On 25/04/2022 23:34, Cameron Simpson wrote:
On 23Apr2022 03:26, Avi Gross wrote:
We know some people using "professional" l
On 4/25/22 16:34, Cameron Simpson wrote:
> On 23Apr2022 03:26, Avi Gross wrote:
>> We know some people using "professional" language make things shorteror
>> talk from a point of view different than others and often in
>> otherwise incomprehensible jargon.
>> If a programmer is taking about the
On 23Apr2022 03:26, Avi Gross wrote:
>We know some people using "professional" language make things shorteror
>talk from a point of view different than others and often in
>otherwise incomprehensible jargon.
>If a programmer is taking about the algorithm that a function implements,
>then, yes,
t;, "Return(s)": "Text",
"Optional-Note": "Text", "French version": DocStringFrench}
Too late to seriously change the language now!
-Original Message-
From: Michael F. Stemper
To: python-list@python.org
Sent: Sun, Apr 24, 2022 9:24 am
Subj
On 25/04/2022 01.24, Michael F. Stemper wrote:
> On 23/04/2022 12.43, Avi Gross wrote:
>> Given what you added, Michael, your function is part of a
>> larger collection of functions and being compatible with the others
>> is a valid consideration. Whatever you decide, would ideally be done
>> consi
On 24/04/2022 08.24, Michael F. Stemper wrote:
On 23/04/2022 12.43, Avi Gross wrote:
Given what you added, Michael, your function is part of a larger collection of
functions and being compatible with the others is a valid consideration.
Whatever you decide, would ideally be done consistently w
On 23/04/2022 12.43, Avi Gross wrote:
Given what you added, Michael, your function is part of a larger collection of
functions and being compatible with the others is a valid consideration.
Whatever you decide, would ideally be done consistently with all or most of
them.
And, of course, it oth
On 23/04/2022 08.35, Michael F. Stemper wrote:
> On 22/04/2022 14.59, Chris Angelico wrote:
>> On Sat, 23 Apr 2022 at 05:56, Michael F. Stemper
>> wrote:
>>>
>>> I'm writing a function that is nearly self-documenting by its name,
>>> but still want to give it a docstring. Which of these would be
>
"return true iff this".
I like this.
jan
On 23/04/2022, Stefan Ram wrote:
> Rob Cliffe writes:
>>I'm curious as to why so many people prefer "Return" to "Returns".
>
> The commands, er, names of functions, use the imperative mood
> ("print", not "prints"). So, "return" aligns with that moo
On Fri, Apr 22, 2022 at 12:56 PM Michael F. Stemper <
michael.stem...@gmail.com> wrote:
> I'm writing a function that is nearly self-documenting by its name,
> but still want to give it a docstring. Which of these would be
> best from a stylistic point of view:
>
>
>Tells caller whether or not
.
-Original Message-
From: Michael F. Stemper
To: python-list@python.org
Sent: Sat, Apr 23, 2022 8:57 am
Subject: Re: Style for docstring
On 22/04/2022 21.58, Avi Gross wrote:
> Python does have a concept of "truthy" that includes meaning for not just the
> standard
On 22/04/2022 16.12, alister wrote:
On Fri, 22 Apr 2022 14:36:27 -0500, Michael F. Stemper wrote:
I'm writing a function that is nearly self-documenting by its name,
but still want to give it a docstring. Which of these would be best from
a stylistic point of view:
for guidance I would suge
On 22/04/2022 21.58, Avi Gross wrote:
Python does have a concept of "truthy" that includes meaning for not just the
standard Booleans but for 0 and non-zero and the empty string and many more odd things
such as an object that defines __bool__ ().
But saying it returns a Boolean True/False value
-Original Message-
From: MRAB
To: python-list@python.org
Sent: Fri, Apr 22, 2022 8:57 pm
Subject: Re: Style for docstring
On 2022-04-23 00:25, Rob Cliffe via Python-list wrote:
> I don't use docstrings much; instead I put a line or two of comments
> after the `def ` line.
> But
user can ignore
or not even catch.
-Original Message-
From: Chris Angelico
To: python-list@python.org
Sent: Fri, Apr 22, 2022 6:33 pm
Subject: Re: Style for docstring
On Sat, 23 Apr 2022 at 08:24, <2qdxy4rzwzuui...@potatochowder.com> wrote:
>
> On 2022-04-22 at 15:35:15 -050
On 2022-04-23 00:25, Rob Cliffe via Python-list wrote:
I don't use docstrings much; instead I put a line or two of comments
after the `def ` line.
But my practice in such situations is as per the OP's 3rd suggestion, e.g.
# Returns True if .
I'm curious as to why so many people prefer "
On 22Apr2022 17:22, Dan Sommers <2qdxy4rzwzuui...@potatochowder.com> wrote:
>"Test whether a permutation is even," while technically factual, leaves
>the reader to wonder what form the result takes, and what happens to
>that result. Yes, we'd all like to think that programmers are smart
>enough to
On Sat, 23 Apr 2022 at 09:31, Rob Cliffe via Python-list
wrote:
>
> I don't use docstrings much; instead I put a line or two of comments
> after the `def ` line.
> But my practice in such situations is as per the OP's 3rd suggestion, e.g.
> # Returns True if .
The point of docstrings is
I don't use docstrings much; instead I put a line or two of comments
after the `def ` line.
But my practice in such situations is as per the OP's 3rd suggestion, e.g.
# Returns True if .
I'm curious as to why so many people prefer "Return" to "Returns".
Checking out help() on a few funct
On 2022-04-23 at 08:33:37 +1000,
Chris Angelico wrote:
> On Sat, 23 Apr 2022 at 08:24, <2qdxy4rzwzuui...@potatochowder.com> wrote:
> >
> > On 2022-04-22 at 15:35:15 -0500,
> > "Michael F. Stemper" wrote:
> >
> > > On 22/04/2022 14.59, Chris Angelico wrote:
> > > > On Sat, 23 Apr 2022 at 05:56, M
On Sat, 23 Apr 2022 at 08:24, <2qdxy4rzwzuui...@potatochowder.com> wrote:
>
> On 2022-04-22 at 15:35:15 -0500,
> "Michael F. Stemper" wrote:
>
> > On 22/04/2022 14.59, Chris Angelico wrote:
> > > On Sat, 23 Apr 2022 at 05:56, Michael F. Stemper
> > > wrote:
> > > >
> > > > I'm writing a function
On 2022-04-22 at 15:35:15 -0500,
"Michael F. Stemper" wrote:
> On 22/04/2022 14.59, Chris Angelico wrote:
> > On Sat, 23 Apr 2022 at 05:56, Michael F. Stemper
> > wrote:
> > >
> > > I'm writing a function that is nearly self-documenting by its name,
> > > but still want to give it a docstring.
On Fri, 22 Apr 2022 14:36:27 -0500, Michael F. Stemper wrote:
> I'm writing a function that is nearly self-documenting by its name,
> but still want to give it a docstring. Which of these would be best from
> a stylistic point of view:
>
>
>Tells caller whether or not a permutation is even.
On 22/04/2022 14.59, Chris Angelico wrote:
On Sat, 23 Apr 2022 at 05:56, Michael F. Stemper
wrote:
I'm writing a function that is nearly self-documenting by its name,
but still want to give it a docstring. Which of these would be
best from a stylistic point of view:
Tells caller whether
On 4/22/22 12:36, Michael F. Stemper wrote:
Tells caller whether or not a permutation is even.
Determines if a permutation is even. (Alternative is that it's odd.)
Returns True if permutation is even, False if it is odd.
Third option.
--
~Ethan~
--
https://mail.python.org/mailman/l
On Sat, 23 Apr 2022 at 05:56, Michael F. Stemper
wrote:
>
> I'm writing a function that is nearly self-documenting by its name,
> but still want to give it a docstring. Which of these would be
> best from a stylistic point of view:
>
>
>Tells caller whether or not a permutation is even.
>
>
27 matches
Mail list logo