[Numpy-discussion] Oddity with numpy.int64 integer division
Tue Apr 24 16:31:05 CDT 2007
On Tue, April 24, 2007 23:08, Robert Kern wrote:
> Christian Marquardt wrote:
>> Restore the invariant, and follow python.
>> >>> -5 // 6
>> >>> array([-5]) // 6
>> simply doesn't make sense - in any language, you would expect that
>> all basic operators provide you with the same same answer when
>> applied to the same number, no?
> Not if they are different types, you don't, e.g. -5.0 / 6 .
But I would regard an integer and an array of integers as the same type.
> Robert Kern
> "I have come to believe that the whole world is an enigma, a harmless
> that is made terrible by our own mad attempt to interpret it as though it
> an underlying truth."
> -- Umberto Eco
> Numpy-discussion mailing list
More information about the Numpy-discussion