#include <bits/stdc++.h>
using namespace std;
int n;
int main() {
  ios_base::sync_with_stdio(false);
  cin >> n;
  long long x, t1 = 0, t2 = 0;
  while (n--) {
    cin >> x;
    t1 += x / 2;
    t2 += x - x / 2;
    swap(t1, t2);
  }
  cout << min(t1, t2);
}
