Home > database >  Program to change the wrong topic, not, bosses give directions
Program to change the wrong topic, not, bosses give directions

Time:09-26


(7) auxiliary 10 Numbers to output the number, the average of 10 # iyelude & lt; Stdio. H>

Roat business (float array [10])

int i;

Float aver, sum=array [0].

* * * * * * * * * *. * * * * * * * * * */
for(i=0; 1<10; 1 + +)
Sum=sum + array [1].
Aver=sum/10.0;
Return (aver);

Int main ()

/* * * * * * * * * * * FOUN * * * * * * * * * * */
Int score [10], aver;
int i;

Printf (" input 10 scores: \ n ");
for(i=0; i<10; I++)

/* * * * * * * FOUND * * * * * * * * * * */the scanf (" % f ", score);
Printf (" \ n ");

/* * * * * * * * * * * FOUND * * * * * * * * * * */
Aver=average (score [10]);

Printf (" average score is 5.2 f "%, aver);
return 0;

}