We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b4d114f commit 331a516Copy full SHA for 331a516
lab-12/occurance-remover.py
@@ -14,4 +14,4 @@ def occurance_remover(file_path, removal_string):
14
file.close()
15
print(f"Removed {occurances} {'occurances' if (occurances != 1) else 'occurance'} of {removal_string} from {os.path.basename(file_path)}")
16
17
-occurance_remover(r"C:\Users\s158658\src\python-programming\lab-12\test.txt", "foo")
+occurance_remover(os.path.expanduser('~') + "\\src\\python-programming\\lab-12\\test.txt", "foo")
0 commit comments