equalsWithTolerance static method

bool equalsWithTolerance(
  1. double x1,
  2. double x2,
  3. double tolerance
)

Implementation

static bool equalsWithTolerance(double x1, double x2, double tolerance) {
  return (x1 - x2).abs() <= tolerance;
}