Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "stdio.h"
- void main (){
- int sum,avg,i,j;
- j=0;
- int a[6] = {92,85,66,89,95,79};
- for ( i = 0; i < 6; i++)
- {
- if (i == 0 || i == 5){
- continue;
- }
- sum+=a[i];
- j++;
- avg = sum/j;
- }
- printf("avg=%d",avg);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement