TypeError: list indices must be integers
Im just setting out on the long road to learn python so please excuse my lack of knowledge.
Im initally trying to read a csv in and print only certain "elements" (not sure if thats the right term) from a list. But I am getting the error : TypeError: list indices must be integers My Code is : Code:
#!/usr/bin/python |
You can't access a list as
Code:
print row[2,5,7] Code:
print row[2],row[5],row[7] Good luck with learning Python! :) |
All times are GMT -5. The time now is 01:14 AM. |