29 Dec
2010
29 Dec
'10
3:20 p.m.
On Wed, 29 Dec 2010 16:13:15 +0100
Georg Brandl
Am 29.12.2010 14:36, schrieb Michael Foord:
Hello all,
I often use python as a calculator or for simple operations using -c. It would be enormously useful if python -c "..." would output on stdout the result of the last evaluated expression in the same way that the interactive interpreter does.
If it did, you couldn't do this anymore (with the obvious implementation):
python -c 'print 1 print 2'
which I guess a few people do rely upon.
A new -e option would be fine, but -- YAGNI?
Apparently, MIGNI.