I'd like to cycle through a list repeatedly (N times) via an iterator, so as not to actually store N copies of the list in memory. Is there a built-in or elegant way to do this without writing my own generator? Ideally, itertools.cycle(my_list) would have a second argument to limit how many times it cycles... alas, no such luck. Continue reading...