ID EN
Pathlib

is_file

Python 3.11

Return True if the path points to a regular file (or a symbolic link pointing to a regular file), False if it points to another kind of file.

Syntax

PYTHON
Path.is_file()