#include <bits/stdc++.h>
#pragma GCC optimize("O3")
using namespace std;
mt19937 rnd(time(nullptr));
const int N = 1e5 + 5;
long long a[N];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  for (int i = 1; i <= n; ++i) cin >> a[i];
  long long first = 0;
  for (int i = 1; i <= n; ++i) first ^= a[i];
  if (n % 2 == 0 && first) cout << "NO", exit(0);
  vector<int> ans;
  for (int i = 3; i <= n; i += 2)
    ans.push_back(i - 2), ans.push_back(i - 1), ans.push_back(i);
  for (int i = n - 4 - (1 - n % 2); i >= 1; i -= 2)
    ans.push_back(i), ans.push_back(i + 1), ans.push_back(i + 2);
  cout << "YES\n" << ans.size() / 3 << "\n";
  for (int i = 0; i < ans.size(); i += 3)
    cout << ans[i] << " " << ans[i + 1] << " " << ans[i + 2] << "\n";
}
