'''
Created on 2018年10月8日
@author: potatomatos
'''
person={'tom','marry','lilei','hanmeimei','tony','lily','tom'};
print(person);#重复的元素会被去掉
#判断元素是否存在set中
if 'tom' in person:
print('存在')
else:
print('不存在')
a=set('hello');
b=set('world');
print(a)
print(a-b)#差集
print(a&b)#交集
print(a|b)#并集
print(a^b)#a和b不同时存在的元素