@sig("a"/ H >> ["a"] >> ["a"] )
def intersperse(x, xs):
    """
    intersperse :: a -> [a] -> [a]

    The intersperse function takes an element and a list and `intersperses'
    that element between the elements of the list.
    """
    def __intersperse(x, xs):
        for y in init(xs):
            yield y
            yield x
        yield last(xs)

    if null(xs):
        return xs
    return L[__intersperse(x, xs)]
dataset/ETHPy150Open billpmurphy/hask/hask/Data/List.py/intersperse/swapped operands of `/`