path

The location of a file or folder written as the folders leading to it, such as /home/ana/notes.txt or C:\Users\ana\notes.txt.

In more detail

Windows separates folders with backslashes and starts with a drive letter; macOS and Linux use forward slashes from /. Gluing path strings together by hand breaks across systems, so use pathlib, which builds the right form with /.

Related terms

Taught in

References