@pointfree<EOL>def pfcollect(iterable, n=None):
if n:<EOL><INDENT>return list(itertools.islice(iterable, n))<EOL><DEDENT>else:<EOL><INDENT>return list(iterable)<EOL><DEDENT>
Collects and returns a list of values from the given iterable.  If
    the n parameter is not specified, collects all values from the
    iterable.

    :param iterable: An iterable yielding values for the list
    :param n: An optional maximum number of items to collect
    :rtype: List of values from the iterable

    Example::

        >>> @pointfree
        ... def fibonaccis():
        ...     a, b = 0, 1
        ...     while True:
        ...         a, b = b, a+b
        ...         yield a

        >>> (pfcollect(n=10) * fibonaccis)()
        [1, 1, 2, 3, 5, 8, 13, 21, 34, 55]