Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Trending News
Python text parsing and field delimiters.?
I have a Python script that is reading URLs from a text file. Some of the URLs will need usernames & passwords. What is the best way to delimit and read the different fields in Python? I need something that can handle delimiter characters inside the URL or password field.
Thanks!
1 Answer
- 1 decade agoFavorite Answer
Use the Python CSV module:
http://docs.python.org/library/csv.html
CSV files are usually delimited by comma, but this module can handle if the delimiter is in the tokens.
CSV files can also be open up be excel.