os.path.isdir(path) Return True if path is an existing directory. This follows symbolic links, so both
linecache.clearcache() Clear the cache. Use this function if you no longer need lines from files previously read using getline()
fileinput.isfirstline() Returns true if the line just read is the first line of its file, otherwise returns false.
right The directory b.
Path.write_text(data, encoding=None, errors=None) Open the file pointed to in text mode, write data to it, and close
shutil.chown(path, user=None, group=None) Change owner user and/or group of the given path.
fnmatch.fnmatchcase(filename, pattern) Test whether filename matches pattern, returning
stat.filemode(mode) Convert a file’s mode to a string of the form ‘-rwxrwxrwx’.
os.path.exists(path) Return True if path refers to an existing path or an open file descriptor. Returns
os.path.abspath(path) Return a normalized absolutized version of the pathname path. On most platforms, this is equivalent
Page 13 of 19