def common_path(l1, l2, common=[]):
    if len(l1) < 1:
        return (common, l1, l2)
    if len(l2) < 1:
        return (common, l1, l2)
    if l1[0] != l2[0]:
        return (common, l1, l2)
    return common_path(l1[1:], l2[1:], common + [l1[0]])
dataset/ETHPy150Open gferreira/hTools2/Lib/hTools2/modules/sysutils.py/common_path/original