Converting a string into a list in Python
- by Sam
I have a text document that contains a list of numbers and I want to convert it to a list. Right now I can only get the entire list in the 0th entry of the list, but I want each number to be an element of a list. Does anyone know of an easy way to do this in Python?
1000
2000
3000
4000
to
['1000','2000','3000','4000']