if( abs(x - y) < 1e-6 ).
Testing for absolute error is often incorrect. Here is a better floating point comparator:9 karma · joined July 6, 2015
if( abs(x - y) < 1e-6 ).
Testing for absolute error is often incorrect. Here is a better floating point comparator: