Untitled

mail@pastecode.io avatar
unknown
c_cpp
7 months ago
256 B
0
Indexable
Never
#include <iostream>
using namespace std;



int main()
{
	int N;
	int sum = 0;
	float cal = 0;
	int mas[100];
	cin >> N;

	
	for (int i = 0; i < N; i++) {
		cin >> mas[i];
		sum += mas[i];
	}

	cal = float(sum) / N;

	cout << cal;
}
Leave a Comment