Dyskusje Q&A
double arr[]={5,2,7,8,11,9};
int n = sizeof(arr) / sizeof(arr[0]);
double sum = 0;
for(int i=0;i<n;i++)
{
sum+= arr[i];
}
double avg = sum / n;
cout<< "avarage ="<< avg<< endl;
return 0;
)
/*what does int n= sizeof(arr[]) /sizeof(arr[0]);
do, can someone explain that line for me*/
0 głosów
3 odpowiedziPopularne dzisiaj
How to make games
5 Votes
About sololearn
0 Votes
HTML
1 Votes
For Mobile app
0 Votes
Answer please
0 Votes
I need advice
0 Votes
I need advice
0 Votes
Paint costs
1 Votes