1 solutions
-
0
#include<bits/stdc++.h> using namespace std; int main() { int T; cin>>T; while(T--) { int cnt=0; int n; cin>>n; for(int i=2;i<=sqrt(n);i++) { if(n%i==0) { cnt++; while(n%i==0) { n/=i; } } } if(n>1) cnt++; // cout<<cnt<<endl; if(cnt==2) cout<<"1"<<endl; else cout<<0<<endl; } return 0; }
- 1
Information
- ID
- 2186
- Time
- 1000ms
- Memory
- 256MiB
- Difficulty
- 9
- Tags
- # Submissions
- 12
- Accepted
- 3
- Uploaded By