基本信息
源码名称:建立一个从 0 到 100 的华氏温度换算为摄氏温度的换算表
源码大小:0.42KB
文件格式:.c
开发语言:C/C++
更新时间:2021-10-06
   友情提示:(无需注册或充值,赞助后即可获取资源下载链接)

     嘿,亲!知识可是无价之宝呢,但咱这精心整理的资料也耗费了不少心血呀。小小地破费一下,绝对物超所值哦!如有下载和支付问题,请联系我们QQ(微信同号):813200300

本次赞助数额为: 2 元 
   源码介绍
建立一个从 0 到 100 的华氏温度换算为摄氏温度的换算表

#include <stdio.h>
#include <stdlib.h>
int main(void)
{
FILE *p;
p=fopen("温度换算表.txt","w");
if((p=fopen("温度换算表.txt","w"))==NULL)
    printf("Failure to open file.\n");
int i,c;
fprintf(p,"华氏温度\t摄氏温度\n");
for(i=0;i<=100;i )
{
c=5*(i-32)/9;
fprintf(p,"%d\t%d\n",i,c);

fclose(p);
printf("Over!");  
return 0;
}