我试过了
filecmp.cmp(file1,file2)
但它不起作用,因为除了换行符之外,文件是相同的.在filecmp或其他一些便利功能/库中是否有选项,或者我必须逐行读取这两个文件并进行比较?
python compare file
compare ×1
file ×1
python ×1