C/math.h/isnan
int isnan(fpval): Returns nonzero if fpval is not a number
#include <stdio.h>
#include <math.h>
int main(void)
{
printf("isnan(-1.0) %d\n", isnan(-1.0));
printf("isnan(1.0) %d\n", isnan(1.0));
printf("isnan(0.0) %d\n", isnan(0.0));
return 0;
}
/*
isnan(-1.0) 0
isnan(1.0) 0
isnan(0.0) 0
*/