Hi

On 12 January 2012 14:38, lina <lina.lastn...@gmail.com> wrote:
> Hi,
>
> there is a file
>
> $ cat atom-pair_9.out | wc -l
> 75426
>
> there is 75426 lines there,
>
>    results=[]
>    unique={}
>    for line in open(tobetranslatedfile,"r"):
>        tobetranslatedparts=line.strip().split()
>        results.append(dictionary[tobetranslatedparts[2]])
>
> it complains
>
>    results.append(dictionary[tobetranslatedparts[2]])
> IndexError: list index out of range
>
>
> is it really too large this file?

Read the error message more carefully.  (Hint: It's not saying
anything about the file at all...)

Walter
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to