Michael Spencer wrote:
> This returns an iterator that 'nests' an arbitrary number of sequences
> (odometer-style).
>
> def nest(*sequences):
> def _nest(outer, inner):
> for outer_item in outer:
> if not isinstance(outer_item, tuple):
> outer_item = (o
john peter wrote:
> I'd like to write two generators: one is a min to max sequence number
> generator that
> rolls over to min again once the max is reached. the other is a generator
> that cycles
> through N (say, 12) labels. currently, i'm using these generators in nested
> loops like
>
I'd like to write two generators: one is a min to max sequence number generator that rolls over to min again once the max is reached. the other is a generator that cycles through N (say, 12) labels. currently, i'm using these generators in nested loops like this: seq_numbers = genSeqNum(min,