delete file in python 3 code example Example: python os remove file import os os.remove("filename.txt")