#include <bits/stdc++.h>
using namespace std;
bool lucky(string a) {
  for (int i = 0; i < a.size(); i++)
    if (a[i] != '4' && a[i] != '7') return 0;
  return 1;
}
int main() {
  int n;
  while (cin >> n) {
    int used[150] = {0};
    for (int i = 0; i < n; i++) {
      int tmp;
      cin >> tmp;
      used[tmp]++;
    }
    int res = 0;
    bool t = 0;
    for (int i = 0; i < 110; i++) {
      res += used[i] / 4;
      used[i] %= 4;
      if (used[i] >= 2) res += t, t = !t;
    }
    cout << res << endl;
  }
  return 0;
}
