I have a .csv files with 9 columns. I need to get a list of the fifth column with no duplicates without using panda. The values in the column are product ID's, so things like "H0073456." There are over 1 million rows in the file. It is almost 4am and I'm getting sad. Help!
It seems like I need to generate a list format of the values in the column but I can't figure out how. Every time I tried I only ever successfully gotten the first value, or each character of the first value separated.
import csv
with open('myfile.csv', 'r') as f_the_file:
reader = csv.reader(f_the_file)
for row in reader:
print(row[4])
This gives me the whole column but still includes the duplicates. How do i filter them out??
The expected result is a list of the values in the 5th column of the .csv file with no duplicates. Right now the output includes duplicate values.