I don't see anything you can do except transforming float to double, and
see what happens.
The while: it is a comparison with floats, and usually I read that is
better compare ints, so you can multiply by 100 and compare to 1 instead
0.01 in the while and transform to int. (In my practices usually I
compare any kind of data, I do like you float to float, double to
double... I don't transform to int and I have not noticed great fails).
|