blitz3d and floats - strange problem

Blitz3D Forums/Blitz3D Beginners Area/blitz3d and floats - strange problem

Just messing around with some code in my game and getting some strange results, so to investigate I simplified the code and STILL got weird results.

value# = 1000

For loop = 1 to 25

print value#
if value# >=0.1
value# = value# - 0.1
end if

Next

Now I'd expect for each loop, I'd get values like 1000, 999.9, 999.8 and so on...

Can someone explain why its goes...

998.1
998.0
997.901
997.801