📅  最后修改于: 2022-03-11 14:45:16.620000             🧑  作者: Mango
# find first item to match condition
# with error if not found
next((x for x in the_iterable if x > 3))
# .. or provide default value if not found
next((x for x in the_iterable if x > 3), default_value)