def act1(): ... def act2(): ... def act3(): ... L = [act1, act2, act3] L[i]() L = [lambda: ..., lambda: ... lambda: ...] L[i]()