Skip to main content

Practice · 2 of 3

Group by Extension

CHALLENGE
Difficulty: intermediate+25 XP

Implement by_suffix(paths) returning a dict mapping suffix (including the dot, lowercase) to a sorted list of path names. Files without a suffix go under ''.

Back to lesson: Practice: pathlib Drills