#include<bits/stdc++.h>
using namespace std;
vector<int>an,ans;
int vs[5005];
int query(int a,int b,int c)
{
cout<<"? "<<a<<" "<<b<<" "<<c<<endl;
int t;
cin>>t;
return t;
}
void sol(int x){
for(int i=0;i<an.size();++i)vs[i]=0;int si=an.size();int o=(x+1)%si;
while(query(an[x],an[o],an[(o+1)%si])<0)vs[o]=1,o=(o+1)%si;
o=(x-1+si)%si;
while(query(an[x],an[o],an[(o+si-1)%si])>0)vs[o]=1,o=(o+si-1)%si;
ans.clear();
for(int i=0;i<si;++i)if(!vs[i])ans.push_back(an[i]);
an=ans;
}
vector<int> convex(int n){
an.clear();
if(query(1,2,3)<0)an.push_back(1),an.push_back(3),an.push_back(2);
else an.push_back(1),an.push_back(2),an.push_back(3);
for(int i=4;i<=n;++i){
if(query(an[0],an[1],i)<0)an.insert(an.begin()+1,i),sol(1);
else{
int l=2,r=an.size();
while(l<r){
int md=l+r>>1;
if(query(an[0],an[md],i)<0)r=md;else l=md+1;
}
if(l==an.size()){
an.push_back(i),sol(an.size()-1);
}else if(query(an[l-1],an[l],i)<0){
an.insert(an.begin()+l,i),sol(l);
}
}
}
cout<<"! "<<an.size()<<" ";
for(auto i:an)
{
cout<<i<<" ";
}
cout<<endl;
}//query(a,b,c):c on ab right:-1