Programming Examples
Python program to delete the specified file from computer
Python program to delete a specified file from Computer
Solution
import os
fname=input("Enter the File Name : ")
os.remove(fname)
print("file deleted")
Output