l = [1,3,2,4,3,5,9,1] l1 = list(set(l)) #set()工厂函数,去重,返回的对象是集合 print(l1)