#include<bits/stdc++.h>
#define ll long long
using namespace std;
const int maxn=2e3+10;
const ll mod=1e9+9;
int n,m,tot=0;
ll cnt=0;
int ans[10];
void dvd(int l,int r){
if(tot==2) return;
while(l<r){
if(tot==2) return;
int mid=(l+r)>>1;
printf("1 %d ",mid-l+1);
for(int i=l;i<=mid;i++){
printf("%d ",i);
}
printf("%d ",r-mid);
for(int i=mid+1;i<=r;i++){
printf("%d ",i);
}
cout<<endl;
char c;
cin>>c;
if(c=='='){
if((mid-l+1)%2==1&&(mid!=l)) mid++;
dvd(l,mid);
dvd(mid+1,r);
return;
}
if(c=='<') r=mid+((mid-l+1)%2==1&&(mid!=l));
else l=mid+1-((mid-l+1)%2==1&&(mid!=l));
}
if(l==r&&tot<2) ans[++tot]=l;
}
int main(){
scanf("%d",&n);
if(n%2==1) div(1,n-1);
else dvd(1,n);
if(!ans[2]) ans[2]=n;
printf("2 %d %d",ans[1],ans[2]);
return 0;
}