+ 2
I'm wondering how and why the results are True, False?! 7.8 > 5 , 10 < 10.0000000000000000001
This is a very very simple python script
8 Antworten
+ 3
What emoji is it? I can't see
+ 3
wondering, confusing
+ 2
Actually 10<10.00000000000000000001 will return False due to the limitations of floating point numbers
+ 2
10.00...001 approximates to 10.0
+ 2
so how can I fix such problems?
+ 2
Floating point numbers have ~6dps of maximum accuracy
+ 2
🙄🤐
+ 1
Cannot