https://tutorial.eyehunts.com/python/python-close-file-function/
Python Close() File | Function