(dir_path=".")
return {
        "files": tuple(sorted(files, key=str.lower)),
        "folders": tuple(sorted(folders, key=str.lower)),
    }
Return a dict containing a sorted tuple of files and a sorted
    tuple of folders
Return a dict containing a sorted tuple of files and a sorted
    tuple of folders
Return a dict containing a sorted tuple of files and a sorted tuple of folders
def files_and_folders(dir_path="."):
    """Return a dict containing a sorted tuple of files and a sorted
    tuple of folders"""
    f_and_f = os.listdir(dir_path)
    folders = [f for f in f_and_f if os.path.isdir(os.path.abspath(f))]
    files = set(f_and_f) - set(folders)
    return {
        "files": tuple(sorted(files, key=str.lower)),
        "folders": tuple(sorted(folders, key=str.lower)),
    }
def files_and_folders ( dir_path = "." ) : f_and_f = os . listdir ( dir_path ) folders = [ f for f in f_and_f if os . path . isdir ( os . path . abspath ( f ) ) ] files = set ( f_and_f ) - set ( folders ) return { "files" : tuple ( sorted ( files , key = str . lower ) ) , "folders" : tuple ( sorted ( folders , key = str . lower ) ) , }