mirror of
https://github.com/Fechin/reference.git
synced 2026-11-20 21:23:11 +03:00
1 file changed
+13
@@ -815,6 +815,19 @@ else:
|
||||
print("Value is True")
|
||||
```
|
||||
|
||||
### match case
|
||||
|
||||
```python
|
||||
x = 1
|
||||
match x:
|
||||
case 0:
|
||||
print("zero")
|
||||
case 1:
|
||||
print("one")
|
||||
case _:
|
||||
print("multiple")
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user