#include using namespace std; #include #include #include #include int data[17][17]; const int LIMIT=16; long long int dp[17][16]; long long int ms[70000][16]; int isV(int p1,int p2){ if(p1>p2){ std::swap(p1,p2); } if(data[p1][p2]==1)return p1; return p2; } void f(int p,std::vector& all,std::vector& Ls,std::vector& Rs){ int s=all.size(); int s2=s/2; if(s==4&&p==0){ int perm1=(1< Ls2,Rs2; f(0,Ls,Ls2,Rs2); f(0,Rs,Ls2,Rs2); int perm1=-1; if(s==4){ perm1=(1<0)&&(Rs.size() all,Ls,Rs; memset(dp,0,sizeof(dp)); memset(ms,-1,sizeof(ms)); for(int i=0;i