Original question: Problem Description assume that a class has n (n <= 50) students and each student takes m (m <= 5) courses, calculate the average score of each student and the average score of each course, and output the number of students whose scores are greater than or equal to the average score. Input data has multiple test instances. The first row of each test instance contains two integers, n and m, indicating the number of students and the number of courses, respectively. Then there are n rows of data, each row contains m integers (I .e., exam scores ). Output outputs three rows of data for each test instance. The first row contains n data, which indicates the average score of n students. The result retains two decimals. The second row contains m data, indicates the average score of the m course, and the result is retained with two decimal places. The third row is an integer, indicating that the scores of all subjects in the class are greater than or equal to the average number of students. Each test instance is followed by a blank line. Sample Input 2 25 1010 20 Sample Output 7.50 15.007.50 15.001 source code: [cpp] # include <stdio. h> # include <string. h> int main () {int n, m; int I, j; int t, d; int s [50]; int c [5]; int SC [50] [5]; while (scanf ("% d", & n, & m )! = EOF) {memset (s, 0, sizeof (s); memset (c, 0, sizeof (c); memset (SC, 0, sizeof (SC )); for (I = 0; I <n; I ++) {for (j = 0; j <m; j ++) {scanf ("% d ", & SC [I] [j]); c [j] + = SC [I] [j]; s [I] + = SC [I] [j];} for (I = 0; I <n; I ++) printf ("%. 2lf % c ", s [I] * 1.0/m, I <n-1? '': '\ N'); for (I = 0; I <m; I ++) printf (" %. 2lf % c ", c [I] * 1.0/n, I <m-1? '': '\ N'); for (t = I = 0; I <n; I ++) {for (d = 1, j = 0; j <m; j ++) {if (SC [I] [j] <1.0 * c [j]/n) {d = 0; break ;}} if (d) t ++;} printf ("% d \ n", t);} return 0 ;}