#include <bits/stdc++.h>
using namespace std;
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long n, X = 0;
  cin >> n;
  long long a[n];
  for (long long i = 0; i < n; i++) {
    cin >> a[i];
    X ^= a[i];
  }
  if (n % 2 == 0 && X != 0) {
    cout << "NO\n";
    return 0;
  }
  if (n % 2 == 0) n--;
  cout << "YES\n" << n - 1 << '\n';
  for (long long i = 0; i < n - 2; i += 2) {
    cout << i + 1 << ' ' << i + 2 << ' ' << i + 3 << '\n';
  }
  for (long long i = n - 2; i >= 0; i -= 2) {
    cout << n << ' ' << i + 1 << ' ' << i << '\n';
  }
}
