To dynamically execute Python code, use a statement of this form:
execE0[inE1[,E2]]
Expression specifies what to execute, and may be a
string containing Python source code, an open file, or
a code object.
If E0
is omitted, the code is executed in the local scope.
If E1
is given but E1
is not, E2
is a dictionary used to define the names in the global and local
scopes.
If E1
is given, E2
is a dictionary defining the global scope, and
E1
is a dictionary defining the local scope.
E2