I am getting a weird problem while parsing a double value in managed C++. It may be that I am doing something wrong. When I do:
double value = 0.006;
result = Math::Parse( value)
The output of result is 0.006000000000001
. Why it is appending a 1?
Also when I go an round the value to 5 decimal places, it fails. I am doing:
result2 = Math::Round(result, 5)
But result2
is always 0.006000000000001
. What am I doing wrong?