yggdrasil/test.c

12 lines
263 B
C
Raw Normal View History

2024-11-11 23:50:38 +02:00
#include <assert.h>
#include <stdio.h>
#include <math.h>
2024-11-12 17:07:06 +02:00
int main(int argc, const char **argv) {
double x = round(1234.123);
assert(fabs(x - 1234.000) < 0.00001);
double y = round(1234.5678);
assert(fabs(y - 1235.000) < 0.00001);
2024-11-11 15:19:36 +02:00
return 0;
}