View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ashish Mathur[_2_] Ashish Mathur[_2_] is offline
external usenet poster
 
Posts: 1,766
Default Problem with = in function

Hi,

If you expand the decimals in F11 and F12, the result is 0.699999999999999.
So the FALSE answer is correct. The reason for the answer not being 0.7 is
conversion of numbers from decimal and binary and vice versa.

To solve this problem, you may use the round function =ROUND(E10,0)=0.7

--
Regards,

Ashish Mathur
Microsoft Excel MVP
www.ashishmathur.com

"Raj" wrote in message
...
Hi,

Please help in understanding this:

Cells d10,d11,d12 have the value 10.7 in them
Cell e10 has the value .7 directly input
Cell e11 has the value .7 derived by the formula =d11-int(d11)
Cell e12 has the value .7 dervied by the formula = e11-trunc(e11)
When values in cells e10,e11,e12 are tested for =.7, cell f10 shows
true, f11 and f12 show false. Why?

Thanks in Advance for the Help.

Raj