Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
99102 黄戈 二进制半整数 C++ 通过 100 106 MS 264 KB 612 2023-08-21 23:45:29

Tests(5/5):


#include <bits/stdc++.h> #define ll long long using namespace std; int main(){ int n,a; cin>>n; for(ll i = 0;i<n;i++){ bool t = false; cin>>a; for(ll j = 0;pow(2,j)<a;j++){ ll cnt = a-pow(2,j); for(ll k = 0;pow(2,k)<=cnt;k++){ if(pow(2,k)==cnt){ cout<<"yes"<<endl; t = 1; break; } } if(t==1){ break; } } if(t==0){ cout<<"no"<<endl; } } return 0; }


测评信息: