fork download
  1. #include <stdio.h>
  2.  
  3.  
  4. // your code goes here
  5. void print_marks(int marks[], int no_of_students);
  6. int main() {
  7. int marks[5]= {40,50,60,70,80};
  8. int no_of_students=5;
  9.  
  10. print_marks(marks,no_of_students);
  11. return 0;
  12. }
  13.  
  14. void print_marks(int student_marks[], int student_count){
  15. for(int i=0;i<student_count;i++){
  16. printf("\n%d",(i+1),student_marks[i]);
  17.  
  18. }
  19. }
Success #stdin #stdout 0s 5288KB
stdin
Standard input is empty
stdout
1
2
3
4
5