提交时间:2024-08-19 15:21:58
运行 ID: 166789
#include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; while(n--) { int x,f=0; cin>>x; for(int i=0;i<=31;i++){ for(int j=0;j<=31;j++){ if(pow(2,i)+pow(2,j)==x){ f=1; break; } } } cout<<(f==1?"yes\n":"no\n"); } return 0; }