[Tutor] Python Lists

2005-07-15 Thread DaSmith
Hi, I am a new Python Programmer, and am encountering some problems with lists. I have created a class which has many "Nested list" attributes. When I create a second instance of the class, the lists are not empty, and already contain the same values as were held in the previous instantiation.

Re: [Tutor] Python Lists

2005-07-17 Thread DaSmith
Thank you Danny, you guessed correctly, problem solved ! Kind Regards, Daniel Smith  -Danny Yoo <[EMAIL PROTECTED]> wrote: -To: [EMAIL PROTECTED]From: Danny Yoo <[EMAIL PROTECTED]>Date: 07/15/2005 10:06PMcc: tutor@python.orgSubject: Re: [Tutor] Python Lists> I have created a class which has

[Tutor] Float Addition

2005-08-17 Thread DaSmith
Hi, I am a relatively new Python Programmer who is a bit puzzled at some of the behavior I am observing. . I have implemented the following loop, to create a running total of distances between 3D co-oordinate tuples, in a group of nodes from a Finite Element Node mesh: for N in range( 2, len(

[Tutor] Searching Sorted Lists

2005-08-19 Thread DaSmith
Hi, Can someone tell me if there is a bulit in Binary search function for python lists ? I am currently building lists and sorting them with a comparison function. The only list search function I know is List.Index(X), which is pretty inefficient I reckon, especially hen the lists are likely t