def deltas(xs):
    """Computes the differences between the elements of a sequence of integers.

    >>> deltas([-1, 0, 1])
    [1, 1]
    >>> deltas([1, 1, 2, 3, 5, 8, 13])
    [0, 1, 1, 2, 3, 5]

    @param xs: A sequence of integers.
    @type xs: C{list}

    @return: A list of differences between consecutive elements of L{xs}.
    @rtype: C{list}
    """
    if len(xs) < 2:
        return []
    else:
        return [xs[1] - xs[0]] + deltas(xs[1:])