python -- figured out how to parse command line args

Delaney, Timothy C (Timothy) tdelaney at
Thu Jun 24 08:10:33 CEST 2004

David Stockwell wrote:

> I figured out how to do it in its simplest form...
> import sys
> for arg in sys.argv:
>     print "arg: ", arg
> I think I saw that in the tutorial, i'd forgotten how though.

The next step is to look at the 'optparse' module.

Tim Delaney

More information about the Python-list mailing list