Run ID | 作者 | 问题 | 语言 | 测评结果 | 分数 | 时间 | 内存 | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|---|
166675 | 07陈鹏睿 | 二进制半整数 | C++ | 运行超时 | 20 | 1000 MS | 272 KB | 518 | 2024-08-19 15:08:39 |
#include <bits/stdc++.h> using namespace std; int main(){ int t;cin>>t; int s[t]; int jg[t]={0}; for (int i=0;i<t;i++){ cin>>s[i]; } for (int x=0;x<t;x++){ for (int y=0;y<sqrt(s[x]);y++){ for (int y1=0;y1<sqrt(s[x]);y1++){ if (pow(2,y)+pow(2,y1)==s[x]){ jg[x]=1; break; } }if (jg[x]==1){ break; } }if (jg[x]==1){ continue; } } for (int i=0;i<t;i++){ if (jg[i]){ cout<<"yes"<<endl; }else{ cout<<"no"<<endl; } } return 0; }