7 lines
78 B
C
7 lines
78 B
C
|
#include <stdlib.h>
|
||
|
|
||
|
int abs(int x) {
|
||
|
int y = x < 0 ? -x : x;
|
||
|
return y;
|
||
|
}
|