How can import a csv file and identify duplicate value in a column? I have to compare each name with other all the names in the same column and identify if there are any duplicate records.
fruits_name_field_num1 = 0
fruits_name_field_num2 = 0
#from collections import Counter
rowCount = 0
fruits_name1 = ''
save_fruits_name1 = ''
for line in readRecord:
rowCount += 1
row_number = str(rowCount)
print(rowCount)
save_fruits_name = fruits_name
fruits_name = (str(line[fruits_name_field_num]))
save_fruits_name = fruits_name
if fruits_name == save_fruits_name:
print('same_fruits_name')
else:
print('different_fruits_name')