#include <bits/stdc++.h>
using namespace std;
long long int mod = 998244353;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long int n, f, s = 0, t = 0, p = 0;
  cin >> n;
  for (int i = 0; i < n; ++i) {
    cin >> f;
    t += f;
    s ^= 1;
    if (f % 2 == 0)
      p += f / 2;
    else {
      p += f / 2;
      if (f % 2 == 1 && s == 1) p += 1;
    }
  }
  cout << min(p, t - p) << endl;
  return (0);
}
