S
Selvam
Hi All,
I am getting exponent value when doing float arithmetic in C++.
Instead of that I need accurate value.
float amount = 0.0f;
float x = 0.99999976f;
amount= 1.0f - x;
I am getting amount as 2.3841858e-007 instead of 0.00000024
Can anyone tell what will
be the solution for this problem???
Note : I am getting correct value in C#.Net but not in C++
Thanks in advance.
Regards,
K
I am getting exponent value when doing float arithmetic in C++.
Instead of that I need accurate value.
float amount = 0.0f;
float x = 0.99999976f;
amount= 1.0f - x;
I am getting amount as 2.3841858e-007 instead of 0.00000024
Can anyone tell what will
be the solution for this problem???
Note : I am getting correct value in C#.Net but not in C++
Thanks in advance.
Regards,
K