#include <bits/stdc++.h>
using namespace std;
int main(int argc, char const *argv[]) {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  int n;
  bool turn = false;
  long long int white = 0;
  long long int black = 0;
  int h;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> h;
    if (h % 2 == 0) {
      white += h / 2;
      black += h / 2;
    } else {
      if (turn) {
        black += h / 2 + 1;
        white += h / 2;
      } else {
        black += h / 2;
        white += h / 2 + 1;
      }
    }
    turn = !turn;
  }
  cout << min(black, white) << '\n';
  return 0;
}
