Do we have python equivalent of 'perl -e'??

Ben Finney bignose+hates-spam at benfinney.id.au
Fri Aug 22 02:25:14 EDT 2008


srinivasan srinivas <sri_annauni at yahoo.co.in> writes:

> Like we run perl small code snippet using perl -e, do we have
> anything like that in python??

It's customary to check the usage summary of the program itself.

=====
$ python --help
usage: python [option] ... [-c cmd | -m mod | file | -] [arg] ...
Options and arguments (and corresponding environment variables):
-c cmd : program passed in as string (terminates option list)
[…]
=====

-- 
 \     “I got some new underwear the other day. Well, new to me.” —Emo |
  `\                                                           Philips |
_o__)                                                                  |
Ben Finney



More information about the Python-list mailing list