Primary
os.path.basename() ⚬|Documentation|1st|20251021184519-00-⌔
os.path — Common pathname manipulations — Python 3 documentation#os.path.basename
os.path.basename(path,/)Return the base name of pathname path. This is the second element of the pair returned by passing path to the function
split(). Note that the result of this function is different from the Unix basename program; where basename for'/foo/bar/'returns'bar', thebasename()function returns an empty string ('').Changed in version 3.6: Accepts a path-like object.
Printed 2026-06-28.
(echo:: @ ᯤ)
Link to original
Secondary
• • •