/* Problem 4--The Temperature Table This one was pretty straightforward. You just print out the Fahrenheit temperatures, with the Centigrade ones thrown in when appropriate. */ #include #include #include int main (int argc, char **argv); FILE *in, *out; int main (int argc, char **argv) { int cs=0, l, h, f; double c, newf; in = fopen ("prob4.in","r"); out = fopen ("prob4.out","w"); while (fscanf(in,"%d %d",&l,&h),l 1e-6 && f < h) /* next line. */ fprintf (out,"\n%21d\n",(int)ceil(c)); else fprintf (out,"\n"); } } fprintf (out,"\n"); } fclose (in); fclose (out); return EXIT_SUCCESS; }