[SciPy-user] question about logical "and" and ndarray in Scipy

Alan G Isaac aisaac at american.edu
Tue Nov 22 20:57:12 CST 2005


On Tue, 22 Nov 2005, "O'Keefe, Michael" apparently wrote: 
> (a>2) and (a<5)

This reminds me:
the difference in SciPy between
(a>2)&(a<5)
and
(a>2 & a<5)
should I think be listed as a "gotcha".
(The operator precedence is surprising.)

fwiw,
Alan Isaac





More information about the SciPy-user mailing list