code: purgatorio

ref: 71292834bbafcf6bc409cfd7691f9e6650df025b
dir: /libkern/abs.c/

View raw version
#include <lib9.h>

int
abs(int a)
{
	if(a < 0)
		return -a;
	return a;
}

long
labs(long a)
{
	if(a < 0)
		return -a;
	return a;
}