4 条题解

  • 2
    @ 2025-3-9 9:05:37

    #include<bits/stdc++.h> using namespace std; int main(){ int a[105]={},k,t; cin>>k; for(int i=1;i<=k;i++){ cin>>t; a[t]++; } for(int i=1;i<=105;i++){ if(a[i]>1){ cout<<"YES"; return 0; } } cout<<"NO"; }

    • 2
      @ 2025-3-9 9:05:26

      #include<bits/stdc++.h> using namespace std; int main() { int a[105]={},k,t; cin>>k; for(int i=1;i<=k;i++){ cin>>t; a[t]++; } for(int i=1;i<=105;i++){ if(a[i]>1){ cout<<"YES"; return 0; } } cout<<"NO"; }

      • 2
        @ 2025-3-9 9:03:51
        #include<bits/stdc++.h>
         using namespace std;
         int main(){
         int a[105]={},k,t;
         cin>>k;
         for(int i=1;i<=k;i++){
            cin>>t;
            a[t]++;
            }
            for(int i=1;i<=105;i++){
                if(a[i]>1){
                    cout<<"YES";
                    return 0;
                }
            }
            cout<<"NO";
           }
        
        • 0
          @ 2025-3-9 9:07:11

          #include<bits/stdc++.h> using namespace std; int main(){ int a[105]={},k,t; cin>>k; for(int i=1;i<=k;i++){ cin>>t; a[t]++; } for(int i=1;i<=105;i++){ if(a[i]>1){ cout<<"YES"; return 0; } } cout<<"NO"; }

          • 1

          信息

          ID
          1111
          时间
          1000ms
          内存
          256MiB
          难度
          3
          标签
          递交数
          154
          已通过
          32
          上传者