Moving Average by ush

float b[999],a;main(i){for(;~scanf("%*s%f",b+i);printf("Score:%5.1f Average:%5.1f\n",b[i++],a/fmin(i,5)))a+=b[i]-b[i-5];}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page