Computer Science, asked by Akhilsingh96431, 1 year ago

How to find if a directory exists in Python?

Answers

Answered by Anonymous
0

Cheapest Way.

from os import listdir

try:

file = listdir('directory goes here')

print('Directory Found!')

except:

print('Directory Not Found')

Similar questions