Answers for "pathlib check is file"

0

pathlib check is file

from pathlib import Path

my_file = Path("/path/to/file")
if my_file.is_file():
    # file exists
Posted by: Guest on January-22-2022

Code answers related to "pathlib check is file"

Python Answers by Framework

Browse Popular Code Answers by Language