Liked on YouTube: Python file detection 📁

Liked on YouTube: Python file detection 📁

Python file detection 📁
Python file detection handling tutorial example explained #python #file #handling import os path = "C:\\Users\\User\\Desktop\\test.txt" if os.path.exists(path): print("That location exists!") if os.path.isfile(path): print("That is a file") elif os.path.isdir(path): print("That is a directory!") else: print("That location doesn't exist!") Bro Code merch store: https://ift.tt/5tUjhN9
via YouTube https://www.youtube.com/watch?v=nZydkTQtSTk

Post a Comment

0 Comments