This repository has been archived on 2025-12-15. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
2024-09-20 14:17:13 +03:00

17 lines
332 B
Python

def checkFileType(filename):
try:
f1 =open(filename)
except FileNotFoundError as fe:
print(fe)
else:
for person in f1:
print(person.strip())
finally:
print("The program ends")
#main program
checkFileType("person.txt")
checkFileType("person1.txt")