Message225365
decimal.Decimal 'floor division' is integer division that truncates toward 0 (see 9.4.2).
>>> Decimal('-0.5').__floor__()
-1
>>> Decimal('-0.5').__floordiv__(1)
Decimal('-0')
Numpy 1.8.1:
>>> np.float32(-0.5) // 1
-1.0
>>> np.float32(-0.5) // float('inf')
-0.0
>>> np.array([-0.5]) // 1
array([-1.])
>>> np.array([-0.5]) // float('inf')
array([-0.]) |
|
Date |
User |
Action |
Args |
2014-08-15 21:20:28 | eryksun | set | recipients:
+ eryksun, tim.peters, rhettinger, mark.dickinson, steven.daprano, skrah |
2014-08-15 21:20:28 | eryksun | set | messageid: <1408137628.18.0.381004209421.issue22198@psf.upfronthosting.co.za> |
2014-08-15 21:20:28 | eryksun | link | issue22198 messages |
2014-08-15 21:20:28 | eryksun | create | |
|