You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# to remmove items from a set you use discard() or remove() your best bet is to use .discard() unless you are very sure that the element in question is really in the set.
# a_set.discard(300)
# a_set.discard('milk')
# print(a_set)
#******* using the .pop() method
print(a_set)
# a_set.pop()
# print(a_set)
# ****this strategy shows you which item was poped out
# fim = a_set.pop()
# print(a_set, fim)
# **** this clears out all the elements of the set.