http://www.pythonreader.com/2024/07/simulate-text-file-in-python.html