Help needed with Statistics Interview Question

Help needed with Statistics Interview Question

alishahsingh20
Explorer Explorer
266 Views
1 Reply
Message 1 of 2

Help needed with Statistics Interview Question

alishahsingh20
Explorer
Explorer

Hello!

I'm having trouble understanding the answer to a statistics interview question from here. I'm trying to find the mean of a given set of data, and I'm not sure how to use the given code to calculate the mean.

The code I'm using is as follows:

int mean(int n, int x[])
{
int sum = 0;
for (int i = 0; i < n; i++)
sum += x[i];

return sum/n;
}

I'm not sure how to use this code to calculate the mean of the given set of data. Any help would be greatly appreciated.

Thank you!

0 Likes
267 Views
1 Reply
Reply (1)
Message 2 of 2

RobDraw
Mentor
Mentor

Why did you choose an AutoCAD forum for this question?


Rob

Drafting is a breeze and Revit doesn't always work the way you think it should.
0 Likes