"bellzii" <[EMAIL PROTECTED]> wrote
> hey everyone , can any1 tell me what does the module optparse do ?


It parses options.
That is it takes a command string and works out what
the various bits mean, in particular the command line
options or "switches".

For example you can call python like this:

$ python -i foo.py

And the -i is an option that tells python not to exity the 
intrerpreter
after running foo.py.

optparse can be usd to validate and select options in your programs.

The documentation includes background info and an extensive
tutorial (this must be one of the best documented modules in
the library) , did you read through it before posting? If so what
did you not understand?

HTH,

Alan G. 


_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to