Problem: You are given an array a of length n that consists of zeros and ones.

You can perform the following operation multiple times. The operation consists of two steps: 

  1. Choose three integers 1 ≤ x < y < z ≤ n, that form an arithmetic progression (y - x = z - y). 
  2. Flip the values a_x, a_y, a_z (i.e. change 1 to 0, change 0 to 1). 



Determine if it is possible to make all elements of the array equal to zero. If yes, print the operations that lead the the all-zero state. Your solution should not contain more than (⌊ n/3 ⌋ + 12) operations. Here ⌊ q ⌋ denotes the number q rounded down. We can show that it is possible to make all elements equal to zero in no more than this number of operations whenever it is possible to do so at all.

Input

The first line contains a single integer n (3 ≤ n ≤ 10^5) — the length of the array.

The second line contains n integers a_1, a_2, …, a_n (0 ≤ a_i ≤ 1) — the elements of the array.

Output

Print "YES" (without quotes) if the answer exists, otherwise print "NO" (without quotes). You can print each letter in any case (upper or lower).

If there is an answer, in the second line print an integer m (0 ≤ m ≤ (⌊ n/3 ⌋ + 12)) — the number of operations in your answer.

After that in (i + 2)-th line print the i-th operations — the integers x_i, y_i, z_i. You can print them in arbitrary order.

Examples

Input

5
1 1 0 1 1


Output

YES
2
1 3 5
2 3 4


Input

3
0 1 0


Output

NO

Note

In the first sample the shown output corresponds to the following solution: 

  * 1 1 0 1 1 (initial state); 
  * 0 1 1 1 0 (the flipped positions are the first, the third and the fifth elements); 
  * 0 0 0 0 0 (the flipped positions are the second, the third and the fourth elements). 



Other answers are also possible. In this test the number of operations should not exceed ⌊ 5/3 ⌋ + 12 = 1 + 12 = 13.

In the second sample the only available operation is to flip all the elements. This way it is only possible to obtain the arrays 0 1 0 and 1 0 1, but it is impossible to make all elements equal to zero.

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 5, M = (1 << 20) + 5;
template <typename T>
void read(T &x) {
  bool neg = false;
  unsigned char c = getchar();
  for (; (c ^ 48) > 9; c = getchar())
    if (c == '-') neg = true;
  for (x = 0; (c ^ 48) < 10; c = getchar()) x = (x << 3) + (x << 1) + (c ^ 48);
  if (neg) x = -x;
}
int n, a[N], k, x[N], y[N], z[N], c[25], xx[25], yy[25], zz[25], m;
bool fail = false;
void op(int u, int v, int w) {
  x[k] = u;
  y[k] = v;
  z[k] = w;
  ++k;
  a[u] ^= 1;
  a[v] ^= 1;
  a[w] ^= 1;
}
void bruteforce(int i) {
  int s = 0, full = (1 << (n - i)) - 1;
  assert(n - i < 11);
  for (int j = n - 1; j >= i; --j) s = s << 1 ^ a[j];
  for (int j = 7, i = 0; j <= full; j <<= 1, ++i)
    xx[m] = i, yy[m] = i + 1, zz[m] = i + 2, c[m++] = j;
  for (int j = 21, i = 0; j <= full; j <<= 1, ++i)
    xx[m] = i, yy[m] = i + 2, zz[m] = i + 4, c[m++] = j;
  for (int j = 73, i = 0; j <= full; j <<= 1, ++i)
    xx[m] = i, yy[m] = i + 3, zz[m] = i + 6, c[m++] = j;
  for (int j = 273, i = 0; j <= full; j <<= 1, ++i)
    xx[m] = i, yy[m] = i + 4, zz[m] = i + 8, c[m++] = j;
  assert(m < 21);
  for (int j = 0, j_end = 1 << m; j < j_end; ++j) {
    int tot = 0;
    for (int kk = 0, kk_end = m; kk < kk_end; ++kk)
      if (j >> kk & 1) tot ^= c[kk];
    if (tot == s) {
      for (int kk = 0, kk_end = m; kk < kk_end; ++kk)
        if (j >> kk & 1) op(xx[kk] + i, yy[kk] + i, zz[kk] + i);
      for (int j = i, j_end = n; j < j_end; ++j) assert(a[j] == 0);
      return;
    }
  }
  fail = true;
}
int main() {
  read(n);
  for (int i = 0, i_end = n; i < i_end; ++i) read(a[i]);
  if (n <= 10)
    bruteforce(0);
  else {
    int i = 0;
    for (; i + 10 < n; i += 6) {
      int s = a[i] << 5 | a[i + 1] << 4 | a[i + 2] << 3 | a[i + 3] << 2 |
              a[i + 4] << 1 | a[i + 5];
      switch (s) {
        case 0:
          break;
        case 1:
          op(i + 5, i + 6, i + 7);
          break;
        case 2:
          op(i + 4, i + 6, i + 8);
          break;
        case 3:
          op(i + 4, i + 5, i + 6);
          break;
        case 4:
          op(i + 3, i + 6, i + 9);
          break;
        case 5:
          op(i + 3, i + 5, i + 7);
          break;
        case 6:
          op(i + 4, i + 5, i + 6);
          op(i + 3, i + 5, i + 7);
          break;
        case 7:
          op(i + 3, i + 4, i + 5);
          break;
        case 8:
          op(i + 2, i + 6, i + 10);
          break;
        case 9:
          op(i + 2, i + 5, i + 8);
          break;
        case 10:
          op(i + 2, i + 4, i + 6);
          break;
        case 11:
          op(i + 2, i + 4, i + 6);
          op(i + 5, i + 6, i + 7);
          break;
        case 12:
          op(i + 2, i + 3, i + 4);
          op(i + 4, i + 6, i + 8);
          break;
        case 13:
          op(i + 3, i + 5, i + 7);
          op(i + 2, i + 6, i + 10);
          break;
        case 14:
          op(i + 2, i + 3, i + 4);
          break;
        case 15:
          op(i + 2, i + 3, i + 4);
          op(i + 5, i + 6, i + 7);
          break;
        case 16:
          op(i + 1, i + 3, i + 5);
          op(i + 3, i + 5, i + 7);
          break;
        case 17:
          op(i + 1, i + 5, i + 9);
          break;
        case 18:
          op(i + 1, i + 4, i + 7);
          break;
        case 19:
          op(i + 1, i + 4, i + 7);
          op(i + 5, i + 6, i + 7);
          break;
        case 20:
          op(i + 1, i + 3, i + 5);
          op(i + 5, i + 6, i + 7);
          break;
        case 21:
          op(i + 1, i + 3, i + 5);
          break;
        case 22:
          op(i + 1, i + 5, i + 9);
          op(i + 3, i + 4, i + 5);
          break;
        case 23:
          op(i + 1, i + 4, i + 7);
          op(i + 3, i + 5, i + 7);
          break;
        case 24:
          op(i + 1, i + 2, i + 3);
          op(i + 3, i + 6, i + 9);
          break;
        case 25:
          op(i + 1, i + 5, i + 9);
          op(i + 2, i + 6, i + 10);
          break;
        case 26:
          op(i + 1, i + 4, i + 7);
          op(i + 2, i + 6, i + 10);
          break;
        case 27:
          op(i + 1, i + 4, i + 7);
          op(i + 2, i + 5, i + 8);
          break;
        case 28:
          op(i + 1, i + 2, i + 3);
          break;
        case 29:
          op(i + 1, i + 2, i + 3);
          op(i + 5, i + 6, i + 7);
          break;
        case 30:
          op(i + 1, i + 2, i + 3);
          op(i + 4, i + 6, i + 8);
          break;
        case 31:
          op(i + 1, i + 2, i + 3);
          op(i + 4, i + 5, i + 6);
          break;
        case 32:
          op(i, i + 2, i + 4);
          op(i + 2, i + 4, i + 6);
          break;
        case 33:
          op(i, i + 5, i + 10);
          break;
        case 34:
          op(i, i + 4, i + 8);
          break;
        case 35:
          op(i, i + 4, i + 8);
          op(i + 5, i + 6, i + 7);
          break;
        case 36:
          op(i, i + 3, i + 6);
          break;
        case 37:
          op(i, i + 3, i + 6);
          op(i + 5, i + 6, i + 7);
          break;
        case 38:
          op(i, i + 3, i + 6);
          op(i + 4, i + 6, i + 8);
          break;
        case 39:
          op(i, i + 3, i + 6);
          op(i + 4, i + 5, i + 6);
          break;
        case 40:
          op(i, i + 2, i + 4);
          op(i + 4, i + 6, i + 8);
          break;
        case 41:
          op(i, i + 2, i + 4);
          op(i + 4, i + 5, i + 6);
          break;
        case 42:
          op(i, i + 2, i + 4);
          break;
        case 43:
          op(i, i + 2, i + 4);
          op(i + 5, i + 6, i + 7);
          break;
        case 44:
          op(i, i + 3, i + 6);
          op(i + 2, i + 6, i + 10);
          break;
        case 45:
          op(i, i + 3, i + 6);
          op(i + 2, i + 5, i + 8);
          break;
        case 46:
          op(i, i + 2, i + 4);
          op(i + 3, i + 6, i + 9);
          break;
        case 47:
          op(i, i + 2, i + 4);
          op(i + 3, i + 5, i + 7);
          break;
        case 48:
          op(i, i + 1, i + 2);
          op(i + 2, i + 6, i + 10);
          break;
        case 49:
          op(i, i + 1, i + 2);
          op(i + 2, i + 5, i + 8);
          break;
        case 50:
          op(i, i + 1, i + 2);
          op(i + 2, i + 4, i + 6);
          break;
        case 51:
          op(i, i + 4, i + 8);
          op(i + 1, i + 5, i + 9);
          break;
        case 52:
          op(i, i + 5, i + 10);
          op(i + 1, i + 3, i + 5);
          break;
        case 53:
          op(i, i + 3, i + 6);
          op(i + 1, i + 5, i + 9);
          break;
        case 54:
          op(i, i + 1, i + 2);
          op(i + 2, i + 3, i + 4);
          break;
        case 55:
          op(i, i + 4, i + 8);
          op(i + 1, i + 3, i + 5);
          break;
        case 56:
          op(i, i + 1, i + 2);
          break;
        case 57:
          op(i, i + 1, i + 2);
          op(i + 5, i + 6, i + 7);
          break;
        case 58:
          op(i, i + 1, i + 2);
          op(i + 4, i + 6, i + 8);
          break;
        case 59:
          op(i, i + 1, i + 2);
          op(i + 4, i + 5, i + 6);
          break;
        case 60:
          op(i, i + 1, i + 2);
          op(i + 3, i + 6, i + 9);
          break;
        case 61:
          op(i, i + 1, i + 2);
          op(i + 3, i + 5, i + 7);
          break;
        case 62:
          op(i, i + 4, i + 8);
          op(i + 1, i + 2, i + 3);
          break;
        case 63:
          op(i, i + 1, i + 2);
          op(i + 3, i + 4, i + 5);
          break;
      }
      assert(!(a[i] | a[i + 1] | a[i + 2] | a[i + 3] | a[i + 4] | a[i + 5]));
    }
    if (i > n - 8) i = n - 8;
    bruteforce(i);
  }
  if (fail)
    puts("No");
  else {
    puts("Yes");
    printf("%d\n", k);
    for (int i = 0, i_end = k; i < i_end; ++i)
      printf("%d %d %d\n", x[i] + 1, y[i] + 1, z[i] + 1);
  }
  return 0;
}