That's the basic problem with float values. You can't store values which can't be represented by the sum of the power of 2
. Thus resulting with the approximate value to your floating point.
e.g. 1.25
can be easily represented as sum of power of 2
i.e. 1*2^0 +1*2^-2
but if you are going to represent 1.33
as sum of power of 2
then the resultant would be 1*2^0 + 1*2^-2 + 1*2^-4 + 1*2^-8 + 1*2^-9 ....
Just read Representable numbers, conversion and rounding on wiki.
And you can check your floating point representation using online tool.