博,博弈论?
大概可以理解成从一个盒子里取出几堆石子,或者对已经取出的盒子做nim博弈,问先手是否必胜//minamoto#include#define R register int#define fp(i,a,b) for(R i=a,I=b+1;i I;--i)using namespace std;char buf[1<<21],*p1=buf,*p2=buf;inline char getc(){return p1==p2&&(p2=(p1=buf)+fread(buf,1,1<<21,stdin),p1==p2)?EOF:*p1++;}int read(){ R res,f=1;char ch; while((ch=getc())>'9'||ch<'0')(ch=='-')&&(f=-1); for(res=ch-'0';(ch=getc())>='0'&&ch<='9';res=res*10+ch-'0'); return res*f;}const int N=15;int p[35],a[N],n;bool ins(R x){ fd(i,30,0)if(x&(1<