Revision history  [back]

CSV Reader

I have been playing with the csv.reader module in reading a column in the following format.

[‘filename1’,
 ‘filename2’,
 ……….. 
]

However, I end up with getting an extra-bracket which I don’t want

[ ( ‘filename1’,
    ‘filename2’, 
   ………….)
]

Just wondering whether you want to suggest me a pythonic way of getting rid of the “ ( “ and “ )”

CSV Reader

Hope you are keeping well. Thank you very much for the Python course. I still need to find time to through every module once again.

I have been playing with the csv.reader module “csv.reader” command in reading a column in the following format.

[‘filename1’, ‘filename2’, ……….. ]

……….. ]

However, I end up with getting an extra-bracket which I don’t want

[ ( ‘filename1’, ‘filename2’, ‘filename2’, ………….) ]

]

Just wondering whether you want to suggest me a pythonic way of getting rid of the “ ( “ and “ )”

I have attached both the script and csv files