<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def path_to_list(pathstr):
 """Conver a path string to a list of path elements."""

    return [elem for elem in pathstr.split(os.path.pathsep) if elem]