Advertisement
PadmaJS

utils.c

Oct 26th, 2022
2,499
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Erlang 0.23 KB | None | 0 0
  1. #include <stdio.h>
  2. int approxEqual(double val, double r, double t)
  3. {
  4.   double upperLimit = r + t;
  5.   double lowerLimit = r - t;
  6.   {
  7.     if (val < upperLimit && val > lowerLimit)
  8.       return 1;
  9.     else
  10.       return 0;
  11.   }
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement