提交时间:2024-08-19 08:20:01

运行 ID: 165940

#include <bits/stdc++.h> using namespace std; int main() { int t; cin >> t; for(int i = 1; i<=t; i++) { int n; cin >> n; bool b = true; while(n!=1) { if(n%2) { b=false; } n/=2; } if(b) { cout << "Yes" << endl; } else { cout << "No" << endl; } } return 0; }