#include <bits/stdc++.h>
using namespace std;
int main() {
  int N, sum;
  cin >> N;
  vector<int> A(N);
  sum = 0;
  for (int i = 0; i < N; i++) {
    cin >> A.at(i);
  }
  for (int i = 0; i < N; i++) {
    sum = sum + A.at(i) * N / 2;
  }
  cout << sum;
}
