#include <bits/stdc++.h>
using namespace std;
map<int, int> oddM;
map<int, int> evenM;
int main() {
  int n;
  cin >> n;
  long long arr[n];
  cin >> arr[0];
  for (int i = 1; i < n; i++) {
    int x;
    cin >> x;
    arr[i] = x ^ arr[i - 1];
  }
  long long counter = 0;
  oddM[0]++;
  for (int i = 0; i < n; i++) {
    if (i % 2 == 0) {
      counter += evenM[arr[i]];
      evenM[arr[i]]++;
    } else if (i % 2 == 1) {
      counter += oddM[arr[i]];
      oddM[arr[i]]++;
    }
  }
  cout << counter;
  return 0;
}
