提交时间:2024-08-19 22:41:03

运行 ID: 168104

#include<iostream> using namespace std; int main() { int n,w,k=2; cin>>n; for(int i=1;i<=n;i++) { cin>>w; while(k<w) { k=k*2; } k=k/2; //cout<<k<<endl; w=w-k; if(w==1 || w%2==0) cout<<"yes"<<endl; else cout<<"no"<<endl; } }