#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 10;
int n;
void work() {
  scanf("%d", &n);
  int ans = 0;
  for (int i = 1; i <= n; ++i) {
    int x;
    scanf("%d", &x);
    ans ^= x;
  }
  if (n % 2 == 0) {
    if (ans != 0) {
      printf("NO\n");
      return;
    }
    n--;
  }
  printf("YES\n");
  printf("%d\n", n - 2);
  for (int i = 1; i + 2 <= n; i += 2) printf("%d %d %d\n", i, i + 1, i + 2);
  for (int i = n - 2; i >= 3; i -= 2) printf("%d %d %d\n", i, i - 1, i - 2);
}
int main() {
  work();
  return 0;
}
