Python集合的方法
阿新 • • 發佈:2018-12-01
增加
add(self, *args, **kwargs)
刪除
clear(self, *args, **kwargs)
pop(self, *args, **kwargs)
remove(self, *args, **kwargs)
discard(self, *args, **kwargs)
獲取
copy(self, *args, **kwargs)
intersection(self, *args, **kwargs)
intersection_update(self, *args, **kwargs)
union(self, *args, **kwargs)
update(self, *args, **kwargs)
difference(self, *args, **kwargs)
difference_update(self, *args, **kwargs)
symmetric_difference(self, *args, **kwargs)
symmetric_difference_update(self, *args, **kwargs)
判斷
isdisjoint(self, *args, **kwargs)
issubset(self, *args, **kwargs)
issuperset(self, *args, **kwargs)