#include <bits/stdc++.h>
using namespace std;
template <class T>
T nrem(T x, T y) {
  return ((x % y) + y) % y;
}
const long long M = 1e9 + 7;
long long mod(long long x) { return ((x % M + M) % M); }
void in() {}
void solve() {
  int n;
  cin >> n;
  int a[n];
  int s = 0;
  for (int i = 0; i < n; ++i) cin >> a[i], s ^= a[i];
  if (n % 2 == 0 && s) {
    cout << "NO"
         << "\n";
    return;
  }
  cout << "YES"
       << "\n";
  if (n % 2 == 0) n--;
  cout << (n - 2) << "\n";
  for (int i = 1; i < n - 1; i += 2)
    cout << i << " " << i + 1 << " " << i + 2 << "\n";
  for (int i = n - 4; i > 0; i -= 2)
    cout << i << " " << i + 1 << " " << i + 2 << "\n";
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  in();
  int t = 1;
  while (t--) {
    solve();
  }
}
