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 + 100;
const int M = 1 << 13;
struct FLIP {
  int x, y, z;
  FLIP(int _x = 0, int _y = 0, int _z = 0) {
    x = _x;
    y = _y;
    z = _z;
  }
};
int a[N], n, p[M];
FLIP op[M];
vector<FLIP> flp;
void flip(int x, int y, int z) {
  a[x] ^= 1;
  a[y] ^= 1;
  a[z] ^= 1;
  flp.push_back(FLIP(x, y, z));
}
void go(int x) {
  if (x == 7)
    flip(n - 2, n - 1, n);
  else if (x == 5)
    flip(n - 4, n - 2, n);
  else if (x == 6)
    flip(n - 3, n - 2, n - 1);
  else if (x == 1)
    flip(n - 6, n - 3, n);
  else if (x == 2)
    flip(n - 5, n - 3, n - 1);
  else if (x == 4)
    flip(n - 4, n - 3, n - 2);
}
void work(int x) {
  if (x == 7)
    flip(n - 5, n - 3, n - 1), flip(n - 8, n - 4, n);
  else if (x == 6)
    flip(n - 9, n - 5, n - 1), flip(n - 8, n - 4, n);
  else if (x == 5)
    flip(n - 9, n - 5, n - 1), flip(n - 6, n - 3, n);
  else if (x == 3)
    flip(n - 4, n - 3, n - 2), flip(n - 2, n - 1, n);
  else if (x == 1)
    flip(n - 5, n - 3, n - 1), flip(n - 10, n - 5, n);
  else if (x == 2)
    flip(n - 6, n - 4, n - 2), flip(n - 2, n - 1, n);
  else if (x == 4)
    flip(n - 8, n - 5, n - 2), flip(n - 2, n - 1, n);
  else
    flip(n - 10, n - 6, n - 2), flip(n - 2, n - 1, n);
}
bool bfs(int s) {
  memset(p, -1, sizeof(p));
  p[s] = 0;
  queue<int> Q;
  Q.push(s);
  int x, y;
  while (!Q.empty()) {
    x = Q.front();
    Q.pop();
    if (x == 0) break;
    for (int i = 0; i < n; ++i) {
      for (int j = i + 1; j < n; ++j) {
        for (int k = j + 1; k < n; ++k) {
          if (k - j != j - i) continue;
          y = x ^ (1 << i) ^ (1 << j) ^ (1 << k);
          if (~p[y]) continue;
          p[y] = x;
          Q.push(y);
          op[y] = FLIP(n - k, n - j, n - i);
        }
      }
    }
  }
  if (p[0] == -1) return false;
  while (x != s) {
    flp.push_back(op[x]);
    x = p[x];
  }
  return true;
}
int main() {
  scanf("%d", &n);
  int x, y;
  for (int i = 1; i <= n; ++i) scanf("%d", &a[i]);
  while (n >= 14) {
    x = 0;
    for (int i = 0; i < 3; ++i) x ^= a[n - i] << i;
    if (x == 3) {
      y = 0;
      for (int i = 0; i < 3; ++i) y ^= a[n - 3 - i] << i;
      work(y);
      n -= 3;
    } else
      go(x);
    n -= 3;
  }
  x = 0;
  for (int i = 0; i < n; ++i) x ^= a[n - i] << i;
  if (bfs(x)) {
    printf("YES\n");
    printf("%d\n", (int)flp.size());
    for (auto p : flp) printf("%d %d %d\n", p.x, p.y, p.z);
  } else
    printf("NO\n");
}