Mel Wilson wrote: > tot = tot + eval ("L%s" % L) > exec is a statement. Yup - OPs wrong usage of exec confused me on that one. Thanks for pointing it out. -- Regards, Diez B. Roggisch