[notes]chap14 Iterator Generator-expression 生成器表达式
generator-expression生成器表达式thedifferencesbetweenlistcomprehensionandgeneratorexpressiondefgen_AB():
print("start")
yield'A'
print("continue")
yield'B'
print("end.")
res1=[x*3forxingen_AB()]执行结果为:start