#includevoid main(){ int sum(int a[],int length); int a[11] = {1,2,1,4,1,6,1,6,1,21,1}; printf("%d",sum(a,11));}int sum(int a[],int length){ int i,sum=0; for(i=0;i { if(i%2==0) { sum += a[i]; } } return sum;}