fork download
  1. #include <stdio.h>
  2. #define student 3
  3. #define exam 4
  4. int muximum(const int grades[][exam]);
  5.  
  6. int main(void) {
  7. int studentsgrades[student][exam]={{77,68,86,73},{96,87,89,78},{70,90,86,81}};
  8. printf("max %d " ,muximum(studentsgrades)) ;
  9.  
  10. return 0;}
  11.  
  12. int muximum(const int grades[][exam]){
  13. int high=0;
  14.  
  15. for(int i=0;i<student;i++)
  16. {for(int j=0;j<exam;j++){
  17. if(grades[i][j]>high)
  18. high=grades[i][j];}};
  19. // your code goes here
  20. return high;}
  21.  
  22.  
Success #stdin #stdout 0s 5280KB
stdin
Standard input is empty
stdout
max 96