Hi! In a class C, I may do setattr(C,'x',10).
Is it possible to use getattr/setattr for variables not inside classes or something equivalent? I mean with the same result as exec("x=10"). Thanks. -- http://mail.python.org/mailman/listinfo/python-list
Hi! In a class C, I may do setattr(C,'x',10).
Is it possible to use getattr/setattr for variables not inside classes or something equivalent? I mean with the same result as exec("x=10"). Thanks. -- http://mail.python.org/mailman/listinfo/python-list