def ljust(x, width, fillchar=' '):
    'analogous to str.ljust, but works for lists'
    if hasattr(x, 'ljust'):
        return x.ljust(width, fillchar)
    else:
        if width < len(x):
            x = (x + [fillchar] * width)[:width]
        return x
dataset/ETHPy150Open Exa-Networks/exabgp/lib/exabgp/dep/cmd2.py/ljust/swapped operands of `<`