I run my python script after launching Python environment in bash. Then I want to examine a variable defined in my script. But I cannot. I wonder how I can run the script in Python while still being able to examine the variables defined in the script after finish running? Note that I don't want to write the values of the variables to a file or stdout. Thanks!
>>> import myscript
>>> myvar
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'myvar' is not defined