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;
template <typename T>
void maxtt(T& t1, T t2) {
  t1 = max(t1, t2);
}
template <typename T>
void mintt(T& t1, T t2) {
  t1 = min(t1, t2);
}
bool debug = 0;
int n, m, k;
int dx[4] = {0, 1, 0, -1}, dy[4] = {1, 0, -1, 0};
string direc = "RDLU";
long long ln, lk, lm;
void etp(bool f = 0) {
  puts(f ? "YES" : "NO");
  exit(0);
}
void addmod(int& x, int y, int mod = 1000000007) {
  assert(y >= 0);
  x += y;
  if (x >= mod) x -= mod;
  assert(x >= 0 && x < mod);
}
void et(int x = -1) {
  printf("%d\n", x);
  exit(0);
}
long long fastPow(long long x, long long y, int mod = 1000000007) {
  long long ans = 1;
  while (y > 0) {
    if (y & 1) ans = (x * ans) % mod;
    x = x * x % mod;
    y >>= 1;
  }
  return ans;
}
long long gcd1(long long x, long long y) { return y ? gcd1(y, x % y) : x; }
int a[100005];
struct ope {
  int x, y, z;
  void pp() { printf("%d %d %d\n", x, y, z); }
};
vector<ope> vp, ans;
void init(int L) {
  vp.clear();
  for (int(i) = 1; (i) <= (int)(L); (i)++)
    for (int(j) = 1; (j) <= (int)(L); (j)++)
      for (int(k) = 1; (k) <= (int)(L); (k)++) {
        if (i < j && j < k && j - i == k - j) {
          vp.push_back({i, j, k});
        }
      }
}
bool ck6(int e) {
  int s = 0;
  for (int(i) = 0; (i) < (int)(6); (i)++) s += a[e - i];
  return s == 0;
}
bool ckall(int e) {
  int s = 0;
  for (int(i) = 1; (i) <= (int)(e); (i)++) s += a[i];
  return s == 0;
}
void cg(int i, int j, int k) {
  a[i] ^= 1;
  a[j] ^= 1;
  a[k] ^= 1;
}
void cgp(ope o) { cg(o.x, o.y, o.z); }
void fmain(int ID) {
  init(11);
  scanf("%d", &n);
  for (int(i) = 1; (i) <= (int)(n); (i)++) scanf("%d", a + i);
  int t = n;
  int N = vp.size();
  for (; t >= 11; t -= 6) {
    if (ck6(t)) continue;
    bool ok = 1;
    for (auto pe : vp) {
      int z = t + 1 - pe.x, y = t + 1 - pe.y, x = t + 1 - pe.z;
      cg(x, y, z);
      if (ck6(t)) {
        ans.push_back({x, y, z});
        ok = 0;
        break;
      }
      cg(x, y, z);
    }
    if (!ok) continue;
    for (int(i) = 0; (i) < (int)(N); (i)++)
      if (ok)
        for (int j = i + 1; j < N; j++) {
          ope tmp = {t + 1 - vp[i].z, t + 1 - vp[i].y, t + 1 - vp[i].x};
          ope tmp1 = {t + 1 - vp[j].z, t + 1 - vp[j].y, t + 1 - vp[j].x};
          cgp(tmp);
          cgp(tmp1);
          if (ck6(t)) {
            ans.push_back(tmp);
            ans.push_back(tmp1);
            ok = 0;
            break;
            ;
          }
          cgp(tmp);
          cgp(tmp1);
        }
  }
  int L = min(n, 10);
  init(L);
  N = vp.size();
  for (int s = 0; s < 1 << N; s++) {
    for (int(j) = 0; (j) < (int)(N); (j)++)
      if (s & (1 << j)) cgp(vp[j]);
    if (ckall(L)) {
      for (int(j) = 0; (j) < (int)(N); (j)++)
        if (s & (1 << j)) ans.push_back(vp[j]);
      break;
    }
    for (int(j) = 0; (j) < (int)(N); (j)++)
      if (s & (1 << j)) cgp(vp[j]);
  }
  if (!ckall(L)) etp();
  puts("YES");
  printf("%d\n", ans.size());
  for (auto p : ans) p.pp();
}
int main() {
  int t = 1;
  for (int(i) = 1; (i) <= (int)(t); (i)++) {
    fmain(i);
  }
  return 0;
}