<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def subdir_path(directory, relative):
 """Returns a file path relative to another path."""

    item_bits = directory.split(os.sep)
    relative_bits = relative.split(os.sep)
    for i, _item in enumerate(item_bits):
        if i == len(relative_bits) - 1:
            return os.sep.join(item_bits[i:])
        else:
            if item_bits[i] != relative_bits[i]:
                return None

    return None