[New-bugs-announce] [issue41393] Fix FAQ example to use __import__('functools').reduce

wyz23x2 report at bugs.python.org
Sat Jul 25 08:38:04 EDT 2020


New submission from wyz23x2 <wyz23x2 at 163.com>:

https://docs.python.org/3/faq/programming.html#is-it-possible-to-write-obfuscated-one-liners-in-python
https://github.com/python/cpython/blob/3.8/Doc/faq/programming.rst
The 3rd raises a NameError because reduce was moved into functools. __import__('functools').reduce should fix this.

----------
assignee: docs at python
components: Documentation
messages: 374258
nosy: docs at python, wyz23x2
priority: normal
severity: normal
status: open
title: Fix FAQ example to use __import__('functools').reduce
versions: Python 3.10, Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41393>
_______________________________________


More information about the New-bugs-announce mailing list