Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<bits/stdc++.h>
- using namespace std;
- #define rep(i,x,y) for(int i=x;i<y;i++)
- #define repr(i,x,y) for(int i=x;i>=y;i--)
- #define int long long
- #define pb push_back
- #define ff first
- #define ss second
- #define sz(x) ((int)x.size())
- #define all(x) begin(x), end(x)
- #define memo(x,y) memset((x),(y),sizeof((x)))
- #define line cout<<"[At "<<__LINE__<<"]"<<endl;
- using pii = pair<int, int>;
- using vi = vector<int>;
- using vii = vector<pair<int, int>>;
- constexpr int mod = 1e9 + 7, N = 2e5 + 5;
- constexpr long long inf = 1e18;
- constexpr long double eps = 1e-6;
- int sum = 0;
- void Onigiri() {
- int x;
- cin >> x;
- x += 4;
- int cnt = 0;
- for(int i = 3; i * i <= x; i++) {
- if(x % i == 0) {
- cnt++;
- break;
- }
- }
- if(cnt)cout << "YES";
- else cout << "NO";
- }
- signed main() {
- ios_base::sync_with_stdio(false);
- cin.tie(NULL);
- //cout.precision(10);cout<<fixed;
- #ifdef Zoro
- freopen("/home/pritish/Competitive/in", "r", stdin);
- freopen("/home/pritish/Competitive/out", "w", stdout);
- #endif
- int t = 1;
- cin >> t;
- while(t--) {
- Onigiri();
- cout << "\n";
- }
- cerr << "\n" << (float)clock() / CLOCKS_PER_SEC * 1000 << " ms" << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement