c program to Convert temperature from centigrade to Fahrenheit.| temperature conversion program in C

Spread the love

Description :

To convert Centigrade to Fahrenheit, multiply by 1.8 and add 32 degrees.

Algorithm:

Step 1 : start
Step 2 : read temperature in centigrade
Step 3 : calculate Fahrenheit = 32 + (centigrade * (1.8));
Step 4 : display centigrade and Fahrenheit
Step 5 : stop.

Flow chart :

Program :

  1. #include<stdio.h>
  2. int main ()
  3. {
  4.         float temp_c, temp_f;
  5.         printf (“Enter the value of Temperature in Celcius: “);
  6.         scanf (“%f”, &temp_c);
  7.         temp_f = (1.8 * temp_c) + 32;
  8.         printf (“The Temperature in Fahreinheit is: %f”, temp_f);
  9.         return 0;
  10. }

Related Programs :

C program to understand type conversation.
finding Largest of two numbers using conditional operator in C.
C program to calculate the simple Interest,
100 + More C programs

Venkatesh Macha

Hi Guys, I am Venkatesh Macha. I am a programmer and an Open Source enthusiast, Presently working as a Software Engineer. Apart from that, I love to explore new technologies and things.

You may also like...

Leave a Reply