[Numpy-discussion] (a and b) != (b and a) ?

Geza Groma groma at nucleus.szbk.u-szeged.hu
Tue Jun 11 23:30:03 EDT 2002


Using Numeric-21.0.win32-py2.2 I found this:

Python 2.2.1 (#34, Apr  9 2002, 19:34:33) [MSC 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from Numeric import *
>>> a = array((1, 1), 'b')
>>> b = array((1, 0), 'b')
>>> a and b
array([1, 0],'b')
>>> b and a
array([1, 1],'b')
>>>

It looks like a bug, or at least very weird. a&b and b&a work correctly.

--
Géza Groma
Institute of Biophysics,
Biological Research Center of Hungarian Academy of Sciences
Temesvári krt.62.
6726 Szeged
Hungary
phone: +36 62 432 232
fax:   +36 62 433 133






More information about the NumPy-Discussion mailing list