Hamish McKenzie wrote:
I want to write a Vector class and it makes the most sense to just
subclass list. I also want to be able to instantiate a vector using either:
Vector( 1, 2, 3 )
OR
Vector( [1, 2, 3] )
so I have this:
class Vector(list):
def __new__( cls, *a ):
try:
Hamish McKenzie wrote:
I want to write a Vector class and it makes the most sense to just
subclass list. I also want to be able to instantiate a vector using either:
Vector( 1, 2, 3 )
OR
Vector( [1, 2, 3] )
so I have this:
class Vector(list):
def
I want to write a Vector class and it makes the most sense to just subclass
list. I also want to be able to instantiate a vector using either:
Vector( 1, 2, 3 )
OR
Vector( [1, 2, 3] )
so I have this:
class Vector(list):
def __new__( cls, *a ):
try:
I want to write a Vector class and it makes the most sense to just subclass
list. I also want to be able to instantiate a vector using either:
Vector( 1, 2, 3 )
OR
Vector( [1, 2, 3] )
so I have this:
class Vector(list):
def __new__( cls, *a ):
try:
print a
Hamish McKenzie [EMAIL PROTECTED] writes:
I want to write a Vector class and it makes the most sense to just
subclass list. I also want to be able to instantiate a vector using
either:
Vector( 1, 2, 3 )
OR
Vector( [1, 2, 3] )
so I have this:
class Vector(list):
def __new__(