<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;">Hi,<br><br>I am trying to create a program where I open a file full of lists and process them.<br>However when the program does not recognize the lists as lists.<br>Here is the relevant code :-<br>def open_filedef():<br>&nbsp;&nbsp;&nbsp; text_file =open ("voteinp.txt","r")<br>&nbsp;&nbsp;&nbsp; lines = text_file.readlines()<br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; for line in lines:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; print line<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; print line[0]<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; text_file.close()<br><br>And an example of the type of text :-<br><br>['a','b','c']<br>['e','d','f']<br><br>Any ideas?<br><br><br>Thanks in advance<br><br><br>David Holland<br></td></tr></table><br>