N/APosted on - 03/31/2017
I have just started learning C language in computers. I am able to solve some easy problems but I have stuck at the problem of how to write a c program to convert fahrenheit to celsius. Does anyone know the source code for this condition? If yes, please post.
How To Write A C Program To Convert Fahrenheit To Celsius For A Beginner.
Here’s your code:
float cs, ft;
printf(“Enter temp. in Fahrenheit: \n”);
// Convert thetemp. from fahrenheit to celsius
cs= (ft- 32) * 5 / 9;
printf(” Temperature in Celsius: %f “, cs);
The output of the program will be