programming-examples/python/Sets/Python program to add member(s) in a set.py
2019-11-15 12:59:38 +01:00

7 lines
165 B
Python

#A new empty set
color_set = set()
color_set.add("Red")
print(color_set)
#Add multiple items
color_set.update(["Blue", "Green"])
print(color_set)