Re: distinction between float & int

2004-12-03 Thread Adam DePrince
On Fri, 2004-12-03 at 09:01, Ishwor wrote: > hi all, > can anyone tell me why this distinction? i mean why it returns False > on floats?? > >>> a = 1 > >>> b = 1 > >>> a is b > True > >>> a = 1.1 > >>> b = 1.1 > >>> a is b > False > >>> > > thanx . > -- > cheers, > Ishwor Gurung In Python, so

Re: distinction between float & int

2004-12-03 Thread Steve Holden
Ishwor wrote: hi all, can anyone tell me why this distinction? i mean why it returns False on floats?? a = 1 b = 1 a is b True a = 1.1 b = 1.1 a is b False thanx . There is no guarantee that this will hold in all implementations of Python. The majority implementation, usually called CPython becaus

distinction between float & int

2004-12-03 Thread Ishwor
hi all, can anyone tell me why this distinction? i mean why it returns False on floats?? >>> a = 1 >>> b = 1 >>> a is b True >>> a = 1.1 >>> b = 1.1 >>> a is b False >>> thanx . -- cheers, Ishwor Gurung -- http://mail.python.org/mailman/listinfo/python-list