helos1/extlib/pdlibc/abs.c

10 lines
92 B
C
Raw Normal View History

2021-10-10 14:39:17 +08:00
#include <stdint.h>
int abs(int val) {
if (val < 0)
return -val;
else
return val;
}