>>> print(list(set(a).intersection(set(b))) [3] 1. 2. 3. 4. 或者 >>> [x for x in a if x in b] [3] 1. 2. 2.3 两个list的差集 >>> a = [1, 2, 3] >>> b = [3, 4, 5] >>> list(set(b).difference(set(a))) [4, 5] >>> list(set(a).difference(set(b...
2. list