// A program that explores floating point arithmetic in the IEEE // floating point standard. The source code is SourcesOfError.C. #include #include #include #include #include int main() { float xs, ys, zs, ws; // Some single precision variables. double yd; // A double precision variable. xs = sqrt(-1); ys = sqrt(xs); zs = sqrt(xs); ys = exp(204.); yd = ys; printf(" is it finite? %d\n",finite(ys)); ws = zs; return(0); }