119924Ssam #define numeric(c) (c>='0' && c<='9') 219924Ssam #define max(a,b) (a<b ? b : a) 319924Ssam #define min(a,b) (a>b ? b : a) 419924Ssam #define abs(x) (x<0 ? -x : x) 519924Ssam 619937Ssam #define copy(src,dest) strcpy(dest,src) 719924Ssam #define compare(str1,str2) strcmp(str1,str2) 819924Ssam #define equal(str1,str2) !strcmp(str1,str2) 919924Ssam #define length(str) strlen(str) 1019924Ssam #define size(str) (1+strlen(str)) 1119924Ssam 1219924Ssam #include "sys/types.h" 1319924Ssam #include "sys/stat.h" 1419924Ssam struct stat Statbuf; 1519924Ssam #define exists(file) (stat(file,&Statbuf)<0 ? 0:Statbuf.st_mode) 1619924Ssam 1719924Ssam #define xfopen(file,mode) fdopen(xopen(file,mode),mode==0?"r":mode==1?"w":"r+w") 1819924Ssam #define xfcreat(file,mode) fdopen(xcreat(file,mode),"w") 1919924Ssam #define remove(file) xunlink(file) 2019924Ssam 21*30505Slepreau #define SCCSID(arg) static char Sccsid[] = "arg" 2219924Ssam 2319924Ssam #define USXALLOC() 2419924Ssam 2519924Ssam #define NONBLANK(p) while (*p==' ' || *p=='\t') p++ 2619924Ssam 2719924Ssam char Null[1]; 2819924Ssam char Error[128]; 29