/*-------------------------------------------------------【程序填空】---------------------------------------------------------题目:给定程序中,函数fun的功能是将形参给定的字符串、整数、浮点数写到文本文件 中,再用字符方式从此文本文件中逐个读入并显示在终端屏幕上。-------------------------------------------------------*/#include <stdio.h>void fun(char *s, int a, double f){/***********SPACE***********/ FILE fp; char str; fp = fopen("file1.txt", "w"); fprintf(fp, "%s %d %f\n", s, a, f); fclose(fp); fp = fopen("file1.txt", "r"); printf("\nThe result :\n\n"); str = fgetc(fp);/***********SPACE***********/ while (!feof(fp)) {/***********SPACE***********/ putchar(str); str = fgetc(fp); } putchar('\n'); fclose(fp);}main(){ char a[10]="Hello!"; int b=12345; double c= 98.76; fun(a,b,c);}