[flacco]
> is there a way to iterate over the *values* in a list/dict/whatever,
> regardless of whether it's a list, dict, or whatever? ie, the iteration
> code will not know beforehand what kind of container it's getting.
try:
it = obj.itervalues()
except AttributeError:
it = iter(obj)
for value in it:
. . .
Raymond Hettinger