import itertools


def peek(iterable):
    """
    Get the first value of an iterator without iterating two times an iterator

    Args:
        iterable: An iterable

    Returns:
        The first value and an iterator to iterate all the values included the first one.

    """
    try:
        first = next(iterable)
    except StopIteration:
        return None, []
    return first, itertools.chain([first], iterable)