New submission from Tom Pohl:

According to the documentation of the floor division 
 x//y should be equal to math.floor(x/y).

However, the result of 1//0.1 is 9.0 (tested on 2.6, 2.7, 3.2).

It might be related to the internal representation of floating-point numbers, 
but for this example I would expect it to come up with the correct values.


components: None
messages: 175424
nosy: Tom.Pohl
priority: normal
severity: normal
status: open
title: Strange results for floor division ("//") with non-integer divisors
type: behavior
versions: Python 2.6, Python 2.7, Python 3.2

Python tracker <>
Python-bugs-list mailing list

Reply via email to