Search Your C Program

Thursday, 26 January 2012

Program to Convert Fahrenheit into Centigrade Degree

#include<stdio.h>
#include<conio.h>
void main()
{
                 float fa,ce;
                 clrscr();
                 printf("\n Enter the temperature into Fahrenheit");
                 scanf("%f",&fa);
                 ce=5.0/9*(fa-32);
                 printf("\n Centigrade Degree = %f",ce);
                 getch();
}

NOTE:= You can also convert centigrade into Fahrenheit by using the formula :
                Fahrenheit = 9.0*centigrade/5+32.

No comments:

Post a Comment