打表 !!
发现,因此只要就可以直接输出 。
其余的的情况打表就行了。
#include<bits/stdc++.h>
using namespace std;
int k;
int T;
int ans[17]={0,0,1,1,2,2,3,3,3,2,2,1,1};
int main(){
cin>>T;
while(T--){
cin>>k;
if(k>12){
cout<<0<<endl;
}
else{
cout<<ans[k]<<endl;
}
}
return 0;
}