#!/usr/local/bin/python2 g = (i for i in range(10)) for j in xrange(1000000): [k for k in g]