It's an optimization in core Python. When a module is imported for the first time, it is stored in the dictionary sys.modules. If a module is already listed there, the existing instance is reused and the file is not reloaded from disk. This is especially noticeable in Pythonista because the entire app internally uses a single Python interpreter instance for the interactive console, user scripts, editor actions, etc. On a normal computer you'd run your program in its own Python process, e. g. by typing python helloworld.py in the shell. That process exits when the program is finished, and sys.modules is discarded. In Pythonista this only happens when the app is removed from the background, either because iOS needs RAM or because you manually quit it.