Hi i am trying to import this csv file to a list:
00cd3de3903a1dd0c5d10a4da5298088
0164d6463da0f5557c18ee5bf3fa40c6
021471774a61276bca2acc70d2605448
025faee9578c97fbaa0da61d55691758
04dd55ae5d18babc028a8410ca34ce10
0524579c38b45ce3f90865a91d4318a4
05a00c320754934782ec5dec1d5c0476
068ed52dae623cbd44c2198cb0eecda3
07dbd191187a3bfbd1d935cabdd82e24
0c3a1172e21000fe43a5b7894f3e0687
the code looks like this:
with open('\\\\ntsrv1\\Indicators_for_Siem\\IOC1.csv', 'r', ) as temp_file:
readCSV = csv.reader(temp_file, delimiter=',')
for row in readCSV:
new_list.append(row)
the output looks like this:
[['00cd3de3903a1dd0c5d10a4da5298088'], ['0164d6463da0f5557c18ee5bf3fa40c6'], ['021471774a61276bca2acc70d2605448'], ['025faee9578c97fbaa0da61d55691758'], ['04dd55ae5d18babc028a8410ca34ce10'], ['0524579c38b45ce3f90865a91d4318a4'], ['05a00c320754934782ec5dec1d5c0476'], ['068ed52dae623cbd44c2198cb0eecda3'], ['07dbd191187a3bfbd1d935cabdd82e24'], ['0c3a1172e21000fe43a5b7894f3e0687']]
not it looks like a list of lists
and i am looking for a pattern of singe list for example:
['value1','value2','value3','value4']
thank you for your assistance
new_list.append(row[0])