Changing Lutz's mydir from Edition 2, Learning Python

Arnaud Delobelle arnodel at googlemail.com
Sun Jan 17 15:34:18 EST 2010


"W. eWatson" <wolftracks at invalid.com> writes:

> See Subject. The code is below with a few changes I made at the bottom
> by inserting
>     import string
>     import numpy
>
>     module = raw_input("Enter module name: ")

replace this line with:

       module_name = raw_input("Enter module name: ")
       module = __import__(module_name)

>     listing(module)
>

HTH

-- 
Arnaud



More information about the Python-list mailing list