aarray = [1,2,3]
barray = [2,3,4]
diff = list(set(aarray)-set(barray))
print(diff)
same = list(set(aarray).intersection(barray))
print(same)
欢迎分享,转载请注明来源:内存溢出
aarray = [1,2,3]
barray = [2,3,4]
diff = list(set(aarray)-set(barray))
print(diff)
same = list(set(aarray).intersection(barray))
print(same)
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)