micropython/tests/basics/set_remove.py

10 wiersze
147 B
Python
Czysty Zwykły widok Historia

2014-01-12 18:23:36 +00:00
s = {1}
print(s.remove(1))
print(list(s))
try:
print(s.remove(1), "!!!")
except KeyError:
pass
else:
print("failed to raise KeyError")