So I’m working on this retarded program for my class and I can’t figure out why it won’t come up with the right answer. It’s supposed to convert Kelvin to Fahrenheit…here’s what I have…
#include<stdio.h>
#include<conio.h>
int main(){
float K, F;
printf(“Please enter a Kelvin temperature.”);
scanf("%f",&K);
F=(((9/5)*(K-273.15))+32);
printf(“The equivalent Fahrenheit temperature is %5.2f.”,F);
getch();
return 0;
}
It comes up with 300 being equal to 58.85 and it’s not, it’s supposed to be 80.33…says the teacher, and a calculator.
It’s probably a dumb mistake, but if anyone can help I’d appreciate it.