漪『』的博客随便写了非常简单的代码 odd_lst=[] for i in range(100): if i%2 == 1: odd_lst.append(i) print(odd_lst) ...问题出现在python的打印设置上,turn off pretty printing,输出就变为正常样子了 ...
西西洛的博客= list2[i]: equal = False break if equal: print("The lists are equal") else: print("The lists are not equal") 以上是比较两个Python列表的一些简单方法。选择哪种方法主要取决于您需要比较什么以及您想用什么...