codescracker


c

C Program to Convert Fahrenheit to Centigrade



« Previous Program Next Program »


Fahrenheit to Centigrade Conversion in C

To convert Fahrenheit temperature to centigrade temperature in C programming, you have to ask to the user to enter the Fahrenheit temperature to convert it into centigrade to display the equivalent temperature value in centigrade

C Programming Code to Convert Fahrenheit to Centigrade

Following C program ask to the user to enter temperature in Fahrenheit to convert it into Centigrade, then display the result on the screen:

/* C Program - Fahrenheit to Centigrade Conversion */
		
#include<stdio.h>
#include<conio.h>
void main()
{
	clrscr();
	float fah, cel;
	printf("Enter temperature in Fahrenheit : ");
	scanf("%f",&fah);
	cel=(fah-32) / 1.8;
	printf("Temperature in Celsius = %f",cel);
	getch();
}

When the above c program is compile and executed, it will produce the following result:

c program convert fahrenheit to centigrade

Same Program in Other Programming Language

You may also like same program in other programming languages:


« Previous Program Next Program »



Tools
Calculator

Quick Links
Signup - Login - Give Online Test