Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- long int v[501],u[10000];
- int main()
- {
- long int n,i,ma=-1;
- cin>>n;
- for(i=1;i<=n;++i)
- cin>>v[i],ma=max(v[i],ma),++u[v[i]];
- for(i=1;i<=ma;i++)
- if(u[i]>1)
- {
- cout<<"NU";
- return 0;
- }
- cout<<"DA";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement