#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<ll,ll> pll;

#define F(type, i, a, b, incr) for (type i = a; i <= (type)(b); i += (type)(incr))
#define pb push_back
#define ppb pop_back
#define ff first
#define ss second
#define iter(it, s) for (auto it = s.begin(); it != s.end(); it++)
#define fillc(a,b) memset(a,b,sizeof(a))
#define MOD 1000000007
#define INF 1e17

void solve()
{
	ll n,i,ans=0,num;
	cin>>n;
	map<ll,ll> mp;
	for(i=0;i<n;i++)
	{
		cin>>num;
		mp[num]++;
	}
	for(auto i:mp)
		ans+=i.ss*(i.ss-1)/2;
	cout<<n*(n-1)/2-ans<<endl;
}

int main()
{
    //freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    cout.tie(0);
        solve();
}
#include<bits/stdc++.h>
using namespace std;
struct node{int n,i;node(int n,int i):n(n),i(i){}};
int n,t,a;
bool b[203];
vector<int>f[203];
vector<node>s;
map<int,vector<node> >all;
void dfs(int x){
	if(x==n){
		int ps=0;
		vector<node>y;
		for(int i=0;i<n;++i)if(b[i])y.push_back(s[i]),ps+=s[i].n;
		ps%=200;
		if(y.size()==0)return;
		if(all[ps].size()>0){
			printf("Yes\n%d ",all[ps].size());
			for(unsigned int i=0;i<all[ps].size();++i)printf("%d ",all[ps][i].i);
			printf("\n%d ",y.size());
			for(unsigned int i=0;i<y.size();++i)printf("%d ",y[i].i);
			exit(0);
		}
		all[ps]=y;
		return;
	}
	b[x]=false;
	dfs(x+1);
	b[x]=true;
	dfs(x+1);
}
int main(){
	scanf("%d",&n);
	for(int i=0;i<n;++i){
		scanf("%d",&a);
		s.push_back(node(a%200,i+1));
		f[a%200].push_back(i+1);
		if(f[a%200].size()==2){
			printf("Yes\n1 %d\n1 %d",f[a%200][0],f[a%200][1]);
			return 0;
		}
	}
	n=s.size();
	dfs(0);
	puts("No");
	return 0;
}