Top-rated recipes tagged "python", "iterable" and "cyclic_iterator"http://code.activestate.com/recipes/tags/python+iterable+cyclic_iterator/top/2014-09-20T19:20:46-07:00ActiveState Code RecipesCycling a sequence (Python)
2014-09-20T19:20:46-07:00Tomas Nordinhttp://code.activestate.com/recipes/users/4189558/http://code.activestate.com/recipes/578942-cycling-a-sequence/
<p style="color: grey">
Python
recipe 578942
by <a href="/recipes/users/4189558/">Tomas Nordin</a>
(<a href="/recipes/tags/cyclic_iterator/">cyclic_iterator</a>, <a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/iterable/">iterable</a>, <a href="/recipes/tags/iterator/">iterator</a>, <a href="/recipes/tags/python/">python</a>).
</p>
<p>A post-it function to cycle through some sequence. Better use itertools.cycle if for any iterable.</p>