提交时间:2024-07-18 11:12:21
运行 ID: 156697
#include<iostream> #include<string> #include<cmath> using namespace std; int main(){ int a,big; cin>>a; int b[a],c[a]; for(int i=0;i<=a-1;i++){ cin>>b[i]; c[i]=0; }for(int i=0;i<=a;i++){ for(int j=0;j<=b[i];j++){ if(std::pow(2,j)==b[i]){ c[i]+=1; } } }for(int i=0;i<=a-1;i++){ if(c[i]==1){ cout<<"Yes"<<endl; }else{ cout<<"No"<<endl; } } }