Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Naive solution in Clear category for Chunk by obone
from typing import Iterable
def chunking_by(items: list, size: int) -> Iterable:
return (items[i:i + size] for i in range(0, len(items), size))
May 4, 2020