You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

10 lines
172 B

a = [1, 2, 3]
print(a.remove(2))
print(a)
try:
a.remove(2)
except ValueError:
print("Raised ValueError")
else:
raise AssertionError("Did not raise ValueError")