1 /* public domain rewrite of finite(3) */ 2 3 int 4 finite(n) 5 double n; 6 { 7 return !isnan(n) && !isinf(n); 8 }