#include <bits/stdc++.h>
using namespace std;
int n;
int a[300005];
long long bla, whi;
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (int i = 1; i <= n; i++) {
    bla += a[i] / 2;
    whi += a[i] / 2;
    if (a[i] % 2 != 0) {
      if (i % 2 == 1)
        whi++;
      else
        bla++;
    }
  }
  printf("%I64d\n", min(bla, whi));
  return 0;
}
