for(i=0;i<n;i++)\r{putc(c[i],fp);\rputchar(c[i]);\r}\rfclose(fp);\r}\r100]\r??6C¸èC¸è3éêNëÇÈÉE 1a>ìíî¸èïðñRéêNëòEvaluationWarning:ThedocumentwascreatedwithSpire.PDFfor.NET.\rÃÄ\rLMNëóXa>wÃÄLM#aÚÞÎÉÖדstud”\r1.\r#$\r2%\r&'(\r#include"stdio.h"\rstructstudent\r(charnum[6];\rcharname[8];\rintscore[3];\rfloatavr;\r>stu[5];\rmain()\r{inti,j,sum;\rFILE*fp;\r/*input*/\rfor(i=0;i<5;i++)\r{printf("\npleaseinputNo.%dscore:\n"zi);\rprintf("stuNo:");\rscanf("?s”,stu[i].num);\rprintf("name:");\rscanf("%s"zstu[i].name);\rsum=0;\rfor(j=0;j<3;j++)\r{printf("score%d."J+l);\rseanf("%dn&stu[i].score[j]);\rz\rsum+=stu[i].score[j];\r}\rstu[i].avr=sum/3.0;\r}\rfp=fopen("stud"z"w");\rfor(i=0;i<5;i++)\rif(fwrite(&stu[i]zsizeof(structstudent),l,fp)!=l)\rprintfC'filewriteerror\n");\rfclose(fp);\r}