flist = [] for i in xrange(3): flist.append(lambda x,_i=i: x * _i) for f in flist: print f(2)