C Program to Convert the Temperature from Celsius to Fahrenheit. Programming With Me.
C Program to Convert the Temperature from Celsius to Fahrenheit. Programming With Me.
# include <stdio.h>
int main()
{
float celsius, fahrenheit;
printf("\n Enter the temprature in Celsius : ");
scanf("%f",&celsius);
fahrenheit = (celsius*9.0)/5+32;
printf("\n Tempareture in fahrenheit : %.2f",fahrenheit);
printf("\n Enter the tempareture in fahrenheit :");
scanf("%f",&fahrenheit);
celsius = (fahrenheit-32)*5/9;
printf("\n Tempareture in Celsius : %.2f",celsius);
return 0;
}
Output
Comments
Post a Comment