[Python-ideas] Add __main__ for uuid, random and urandom
Joao S. O. Bueno
jsbueno at python.org.br
Fri Apr 1 19:10:51 EDT 2016
On 1 April 2016 at 19:47, Mark Lawrence via Python-ideas
<python-ideas at python.org> wrote:
> On 01/04/2016 21:42, Ethan Furman wrote:
>> On 04/01/2016 01:35 PM, Joao S. O. Bueno wrote:
>>> Well...actually, really recently (Tuesday), I did
>>> python3 -c "__import__('calendar').calendar(2016)"
>> Wouldn't have
>> python3 -c "import calendar; calendar(2016)"
>> been clearer? and easier to type? :)
It would, but python3 -c "import calendar; calendar.calendar(2016)"
not so much easier to type.
The reason, however is that I usually think of "I have the right to
use one single expression when using python -c" and not "a single
> My understanding is that this kind of construction does not make you as much
> money when you are a consultant, as opposed to a mere programmer or similar.
Or that ^ :-)
Anyway - back to the thread - it does not seen a bad idea for me at all.
> My fellow Pythonistas, ask not what our language can do for you, ask
> what you can do for our language.
> Mark Lawrence
> Python-ideas mailing list
> Python-ideas at python.org
> Code of Conduct: http://python.org/psf/codeofconduct/
More information about the Python-ideas