Dyskusje Q&A
C++ homework: puzzle
0 głosów
8 odpowiedzidouble 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 odpowiedziWhere i am going wrong help
2 głosów
2 odpowiedziPopularne dzisiaj
Web Development
3 Votes
Cybersecurity techies
4 Votes
Please complete this code.
0 Votes
What's wrong with code?
0 Votes
Please answer.
0 Votes
How do you print inputs
0 Votes
Introduction of html
0 Votes