#include <bits/stdc++.h>
using namespace std;

int main(){
    long long n;
    cin >> n;
    double N = sqrt(n);
    int count = 0;
    /*vector<long long> vec(n, 2000000000000);*/
    priority_queue<long long, vector<long long>, greater<long long>> Q1;
    for (int i = 1; i <= N; i++){
        if (n % i == 0 && i != n /i){
            Q1.push(i);
            Q1.push(n / i);
            /*vec[i] = i;
            vec[n / i] = n / i;*/
            count += 2;
        }
      	if (n % i == 0 && i == n /i){
            Q1.push(i);
            count++;
        }
    }
    /*sort(vec.begin(), vec.end());*/

    /*for(int i = 0; i < count; i++){*/
    while(count > 0){
        cout << Q1.top() << endl;
        Q1.pop();
        count--;
    }
        
}
#include <bits/stdc++.h>
using namespace std;
// clang-format off
// #include <atcoder/all>
// using namespace atcoder;
// using mint = modint1000000007;
// using mint = modint998244353

using ll = int64_t;
template <class T>
istream& operator>>(istream& is, vector<T>& v) {
    for (auto& a : v) cin >> a;
    return is;
}
template <class T>
istream& operator>>(istream& is, vector<pair<T, T>>& v) {
    for (auto& a : v) cin >> a.first >> a.second;
    return is;
}
template <class T>
istream& operator>>(istream& is, vector<tuple<T, T, T>>& v) {
    for (auto& a : v) {
        T a1, a2, a3;
        cin >> a1 >> a2 >> a3;
        a = {a1, a2, a3};
    }
    return is;
}
template <class T>
ostream& operator<<(ostream& os, vector<T>& v) {
    for (auto& a : v) os << a << " ";
    os << endl;
    return os;
}
template<class T>
bool chmin(T &a, T b) {
    if (a > b) { a = b; return true; } 
    return false;
}
template<class T>
bool chmax(T &a, T b) {
    if (a < b) { a = b; return true; } 
    return false;
}
#define all(v) begin(v), end(v)
#define rall(v) rbegin(v), rend(v)
#define TRC1(a) cout << #a ":" << a
#define TRC2(a, b) TRC1(a); cout << " "; TRC1(b)
#define TRC3(a, b, c) TRC2(a, b); cout << " "; TRC1(c)
#define TRC4(a, b, c, d) TRC3(a, b, c); cout << " "; TRC1(d)
#define GET_NAME(_1,_2,_3,_4,NAME,...) NAME
#define TRC(...) GET_NAME(__VA_ARGS__, TRC4, TRC3, TRC2, TRC1) (__VA_ARGS__) << endl
using veci = vector<int>;
using vecll = vector<ll>;
using Pi = pair<int, int>;
using Ti = tuple<int, int, int>;
#define _overload3(_1,_2,_3,name,...) name
#define _rep(i,n) repi(i,0,n)
#define repi(i,a,b) for(int i=int(a);i<int(b);++i)
#define rep(...) _overload3(__VA_ARGS__,repi,_rep,)(__VA_ARGS__)
const int IINF = INT32_MAX;
const ll LINF = INT64_MAX;

// cout << fixed << setprecision(15);
void solve();
int main() { 
    cin.tie(0); ios::sync_with_stdio(0);
    cout << fixed << setprecision(15); solve(); return 0; }
// clang-format on

void calc(int n) {
    int i = 1;
    veci a;
    while (n > 0) {
        if (n & 1) a.push_back(i);
        ++i;
        n >>= 1;
    }
    cout << a.size() << " ";
    for (int x : a) {
        cout << x << " ";
    }
    cout << endl;
}

void solve() {
    int N;
    cin >> N;
    veci A(N);
    cin >> A;
    N = min(N, 8);
    veci s(200);
    rep(i, 1, 1 << N) {
        int sum = 0;
        rep(j, N) if (i >> j & 1) sum = (sum + A[j]) % 200;
        if (s[sum] == 0) s[sum] = i;
        else {
            cout << "Yes" << endl;
            calc(s[sum]);
            calc(i);
            return;
        }
    }
    cout << "No" << endl;
}
