I have a little problem with my distance calculation function, here is a screenshot of a playground where we see that distance variable == NaN (instead of 0) when tsum == 1
in fact at runtime (in my real app, in simulator), t1 + t2 + t3 == 1.0000000000000002
its really strange because when i manually calculate it, i have 1
but ios seems to not agree that. Can you explain that ?
P.S : Here is a link to the playground https://drive.google.com/drive/folders/0B6uRRn4bFMAeN3kwSVc4dUVQcDQ?usp=sharing
P.S.2 : i give a screenshot to prove that i'm not manipulating values: