[Python-Dev] Informal educator feedback on PEP 572 (was Re: 2018 Python Language Summit coverage, last part)
steve at pearwood.info
Sat Jun 23 01:52:07 EDT 2018
On Fri, Jun 22, 2018 at 09:08:37PM -0700, Chris Barker wrote:
> > So if you absolutely need to teach it to a beginner, it
> > shouldn't be difficult once they understand the difference between an
> > expression and a statement.
> probably not, though that's a distinction that's mostly academic in the
> early stages of learning,
I don't think so.
People do try to use assignment in expressions, even if only by mistake
writing = when they meant == and need to distinguish between them. In
Python 2, the most common clash between statements and expressions was
print, but at least that's gone.
Even without assignment expressions, people still need to know why they
can't write "if mo = re.match(pattern, text)".
> again, not a huge deal, just a little bit more complexity
Every new feature is added complexity.
More information about the Python-Dev