values = [1, 2, 3, 4, 5] # bind and test in one step if (n := len(values)) > 3: print(f"{n} items")
:= assigns inside an expression