← Back to Question List
Python Quiz #62
Assign And Test In One Go
What does the walrus operator := do, and what does this program print?
📄 Code
1nums: list[int] = [3, 8, 2]2if (n := len(nums)) > 2:3 print(f"{n} numbers")