Importing two module variables and having one clobber the other?
Joseph Turian
turian at gmail.com
Tue Mar 21 17:05:49 EST 2006
Fredrik Lundh wrote:
> if you prefer to use a "parameters.value" syntax, you can wrap the resulting
> dictionary in a class.
That sounds good. How do I do that?
> I assume "from" means "beneath" and "getcwd" means "walk" ?
Actually:
def superdirs(d):
lst = [d]
while d != os.environ["HOME"]:
(d, tl) = os.path.split(d)
lst += [d]
lst.reverse()
return lst
Joseph
More information about the Python-list
mailing list