提交时间:2024-07-17 22:26:26
运行 ID: 156589
#include<bits/stdc++.h> using namespace std; int a,b,c,d[105],e,f,g; bool cifang(int x) { int y; for(y=1;y<=x;y*=2); cout<<y<<endl; if(y==x*2) return 1; return 0; } int main() { cin>>a; for(b=1;b<=a;b++) { cin>>c; if(c%2==0) d[b]=1; else d[b]=cifang(c-1); } for(b=1;b<=a;b++) if(d[b]==1) cout<<"yes"<<endl; else cout<<"no"<<endl; return 0; }