提交时间:2024-06-05 19:25:43
运行 ID: 150580
#include<bits/stdc++.h> using namespace std; int main (){ int n; long long x; cin>>n; for(int i=1;i<=n;i++){ cin>>x; if((x==1)||(x&1)&&((x-1)&(x-2))!=0)cout<<"No"<<endl; else { while (!(x&1)) x>>=1; x--; if ((x&(x-1)))cout<<"no"<<endl; else cout<<"yes"<<endl; } } return 0; }