Thursday, 30 August 2012

If the marks obtained by a student in five different subjects are input through the keyboard, find out the aggregate marks and percentage marks obtained by the student. Assume that the maximum marks that can be obtained by a student in each subject is 100.

 int s1,s2,s3,s4,s5,agr;
 float per;
 printf("Enter the marks of a student in five subject\n");
 printf("He got %d marks in aggregate\n",agr);
 printf("He got %5.2f %c of marks",per,37);


No comments:

Post a Comment