#include <bits/stdc++.h>
using namespace std;
long long n, c1, c2, s[300300];
signed main() {
  scanf("%lld", &n);
  for (long long i = 1; i <= n; i++) scanf("%lld", &s[i]);
  for (long long i = 1; i <= n; i++) {
    c1 += s[i] / 2;
    c2 += s[i] / 2;
    if (s[i] % 2 == 1) {
      if (i % 2 == 0)
        c2++;
      else
        c1++;
    }
  }
  printf("%lld", min(c1, c2));
  return 0;
}
