C语言 输入任意华氏度,输出相应摄氏度。求大神帮我看看我写的对不对!
#inclued <stdio.h>void main()
{
int a,c,f;
a=f-32;
c=a/1.8;
scanf("%f",&f);
printf("c is %-4.2f\n",c);
}
这个代码是不是能编辑出:c=(f-32)/1.8
#include <stdio.h> int main() { float a,f; scanf("%f",&f); a=(f-32)/1.8; printf("c is %-4.2f\n",a); return 0; }