#include <bits/stdc++.h>
using namespace std;
long long n, a, b, w;
int main() {
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> a;
    w += a / 2;
    b += a / 2;
    if (a % 2 == 1) {
      w = w + i % 2;
      b = b + 1 - i % 2;
    }
  }
  cout << min(b, w);
  return 0;
}
