#!/usr/local/bin/python2 it = (e for e in [1,2,3] if e <= 2) print next(it)