Problem:
convert the value in Fahrenheit into degree , and relationship between degree and Fahrenheit is D=(F-32)*1.8
solution:
#include<stdio.h>
#include<conio.h>
void main()
{
float deg,frn;
clrscr();
printf("enter the Fahrenheit");
scanf("%f",&frn);
deg=(frn-32)/1.8;
printf("the %.2fF---> %.2f deg",frn,deg);
getch();
}
Output
convert the value in Fahrenheit into degree , and relationship between degree and Fahrenheit is D=(F-32)*1.8
solution:
#include<stdio.h>
#include<conio.h>
void main()
{
float deg,frn;
clrscr();
printf("enter the Fahrenheit");
scanf("%f",&frn);
deg=(frn-32)/1.8;
printf("the %.2fF---> %.2f deg",frn,deg);
getch();
}
Output
No comments:
Post a Comment