def unpack_default(iterable, length=3, default=None):
    """
    Unpacks given iterable maintaining given length and filling missing entries with given default.

    :param iterable: iterable.
    :type iterable: object
    :param length: Iterable length.
    :type length: int
    :param default: Filling default object.
    :type default: object
    :return: Unpacked iterable.
    :rtype: object
    """

    return itertools.islice(itertools.chain(iter(iterable), itertools.repeat(default)), length)
def unpack_default ( iterable , length = 3 , default = None ) : return itertools . islice ( itertools . chain ( iter ( iterable ) , itertools . repeat ( default ) ) , length )
Unpacks given iterable maintaining given length and filling missing entries with given default.

    :param iterable: iterable.
    :type iterable: object
    :param length: Iterable length.
    :type length: int
    :param default: Filling default object.
    :type default: object
    :return: Unpacked iterable.
    :rtype: object