>len = len(dirs)The function 'len' is a built-in function in Python. If you assign an
integer to the name 'len', that will replace the function with an int. And
you can't call an int.
My suggestion: Do not use 'len' as a variable name. Use something else, like:
directorycount=len(dirs)
Greetings,
<type 'builtin_function_or_method'>>>type(len)
6>>print len("Victor")
>>len=42
<type 'int'>>>type(len)
Traceback (most recent call last):>>len("Victor")
File "<pyshell#4>", line 1, in <module>
len("Victor")
TypeError: 'int' object is not callable
--
"The ability of the OSS process to collect and harness
the collective IQ of thousands of individuals across
the Internet is simply amazing." - Vinod Vallopillil
http://www.catb.org/~esr/halloween/halloween4.html