On Nov 25, 10:51 pm, Paul Rubin <http://phr...@NOSPAM.invalid> wrote: > Really though, this grouping function gets reimplemented so often that > it should be built into the stdlib, maybe in itertools. thanks Paul. itertools? that was actually the first module i checked.