#include <bits/stdc++.h>
using namespace std;
const int N = 300005;
int n, a[N], t, Q[N][4];
int main() {
  scanf("%d", &n);
  int x = 0;
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]), x ^= a[i];
  if (n % 2 == 0 && x) {
    puts("NO");
    return 0;
  }
  if (x == 0) n--;
  for (int i = 3; i <= n; i += 2)
    Q[++t][0] = i - 2, Q[t][1] = i - 1, Q[t][2] = i;
  for (int i = n - 1; i >= 2; i -= 2)
    Q[++t][0] = n, Q[t][1] = i, Q[t][2] = i - 1;
  printf("YES\n%d\n", t);
  for (int i = 1; i <= t; i++) printf("%d %d %d\n", Q[i][0], Q[i][1], Q[i][2]);
  return 0;
}
