Re: [Tutor] Python on Windows: any way to access shortcut's info?

2006-01-08 Thread Kent Johnson
Terry Carroll wrote: > I would like to know the name of the shortcut (link, I think, in Unix > parlance) from which a python program is being invoked. I'd also like to > be able to access the directory where the shortcut lives. You can set the command line arguments and working directory for a s

[Tutor] Python on Windows: any way to access shortcut's info?

2006-01-08 Thread Terry Carroll
I would like to know the name of the shortcut (link, I think, in Unix parlance) from which a python program is being invoked. I'd also like to be able to access the directory where the shortcut lives. Toy example: here's a directory structure: C:\ test\ argtest\ arga.py ar

Re: [Tutor] IndexError: list index out of range [ Program work fine , but gives this message , guidance requested ]

2006-01-08 Thread Brian van den Broek
John Joseph said unto the world upon 08/01/06 06:36 AM: > --- Guillermo Fernandez Castellanos > <[EMAIL PROTECTED]> wrote: > > >>Hi, >> >>Look at this: >> >>> i=[1,2,3] >> >>> i[len(i)] >>Traceback (most recent call last): >> File "", line 1, in ? >>IndexError: list index out of range >> >> >>T

[Tutor] Landscape Printing

2006-01-08 Thread John Corry
Hi, My text file is printing out in portrait. Is there any instruction that I can use so that notepad prints it in landscape? Thanks, John. ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] IndexError: list index out of range [ Program work fine , but gives this message , guidance requested ]

2006-01-08 Thread John Joseph
--- Guillermo Fernandez Castellanos <[EMAIL PROTECTED]> wrote: > Hi, > > Look at this: > >>> i=[1,2,3] > >>> i[len(i)] > Traceback (most recent call last): >File "", line 1, in ? > IndexError: list index out of range > > > This means that I have tried to access an element > that is out o

Re: [Tutor] IndexError: list index out of range [ Program work fine , but gives this message , guidance requested ]

2006-01-08 Thread Guillermo Fernandez Castellanos
Hi, Look at this: >>> i=[1,2,3] >>> i[len(i)] Traceback (most recent call last): File "", line 1, in ? IndexError: list index out of range This means that I have tried to access an element that is out of the list, in this case i[3], that is, the 4th element of the list. You are doing the

[Tutor] IndexError: list index out of range [ Program work fine , but gives this message , guidance requested ]

2006-01-08 Thread John Joseph
Hi All I am trying to find out the duplicates in a list , as for beginning I wanted to compare the adjacent elements in list , for this purpose I wrote a script for checking the adjacent elements in a list, if same , it prints the result that , the adjacent numbers are same , it not it wi