match — Easy Playground
Begins a structural pattern matching block (3.10+)
Python Playground
Output
Click "Run" to execute your codematch/case is Python's structural pattern matching (3.10+). The _ wildcard matches anything. Use | for OR patterns.
Challenge
Try modifying the code above to explore different behaviors. Can you extend the example to handle a new use case?