/* This program takes temperature in
Fahrenhites as input from user converts it into
degree celsius and then shows results
.*/
#include<stdio.h>
#include<conio.h>
int main()
{
/*Declaring and initializing variables*/
float celcius = 0;
float fahrenhite =0;
/*prompt for input*/
printf("\nPlease enter the temperature in Degree
Fahrenhites: ");
/*Taking temperature in fahrenhite as input from user*/
scanf("%f",&fahrenhite);
/*Calculations*/
celcius =
(5.0*(fahrenhite-32))/9.0;
/*showing results*/
printf("\nTemperature is %f degree celcius",celcius);
getche();
return 0;
}
Check my blog www.whatilearn.info for complete solution of Let us C solutions
ReplyDelete