--- from: http://rosettacode.org/wiki/Pathological_floating_point_problems