Return the records with the selected columns

    :param records: a list of dictionaries
    :param columns: a list or a tuple
    :returns: a list of dictionaries with the selected columns

    >>> movies = [
    ... {'title': 'The Holy Grail', 'year': 1975, 'budget': 4E5, 'total_gross': 5E6},
    ... {'title': 'Life of Brian', 'year': 1979, 'budget': 4E6, 'total_gross': 20E6},
    ... {'title': 'The Meaning of Life', 'year': 1983, 'budget': 9E6, 'total_gross': 14.9E6}
    ... ]
    >>> pluck_each(movies, ('title', 'year'))
    [{'year': 1975, 'title': 'The Holy Grail'}, {'year': 1979, 'title': 'Life of Brian'}, {'year': 1983, 'title': 'The Meaning of Life'}]

def pluck_each(records, columns):
    """Return the records with the selected columns

    :param records: a list of dictionaries
    :param columns: a list or a tuple
    :returns: a list of dictionaries with the selected columns

    >>> movies = [
    ... {'title': 'The Holy Grail', 'year': 1975, 'budget': 4E5, 'total_gross': 5E6},
    ... {'title': 'Life of Brian', 'year': 1979, 'budget': 4E6, 'total_gross': 20E6},
    ... {'title': 'The Meaning of Life', 'year': 1983, 'budget': 9E6, 'total_gross': 14.9E6}
    ... ]
    >>> pluck_each(movies, ('title', 'year'))
    [{'year': 1975, 'title': 'The Holy Grail'}, {'year': 1979, 'title': 'Life of Brian'}, {'year': 1983, 'title': 'The Meaning of Life'}]

    """
    return [pluck(records[i], *columns) for i, _ in enumerate(records)]