5 条题解

  • 0
    @ 2024-2-29 16:48:51
    #include<bits/stdc++.h>
    using namespace std;
    int main(){
        int n;
        cin>>n;
        for(int i=0;i<n;i++){
            for(char j='A';j<n+'A';j++){
            	cout<<j;
            }
            cout<<endl;
        }
        return 0;
    }
    
    • 0
      @ 2023-10-23 19:27:31
      #include <bits/stdc++.h>
      using namespace std;
      int main()
      {
          char c = 'A';
          int n;
          cin >> n;
          for (int i = 1; i <= n; i++)
          {
              for (int j = 1; j <= n; j++)
              {
                  cout << c;
                  c++;
              }
              cout << endl;
              c = 'A';
          }
          return 0;
      }
      
      • 0
        @ 2023-10-2 21:06:51
        #include<bits/stdc++.h>
        using namespace std;
        int main()
        {
            int n;
            cin>>n;
            for(int i=0;i<n;i++)
            {
                char x;
                for(int j=0;j<n;j++)
                {
                    x='A'+i;
                    cout<<x;
                }
                cout<<endl;
            }
            return 0;
        }
        
        • 0
          @ 2023-5-31 15:44:56
          #include <bits/stdc++.h>
          using namespace std;
          int n;
          char a;
          int main()
          {
              cin >> n;
              for (int i = 1; i <= n; i++)
              {
                  a = 'A';
                  for (int j = 1; j <= n; j++)
                  {
                      cout << a;
                      char (a += 1);
                  }
                  cout << endl;
              }
              return 0;
          }
          
          • -1
            @ 2023-10-4 9:27:38
            #include<iostream>
            using namespace std;
            int main()
            {
            int n;
            cin>>n;
            if(n == 1)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"A";
            }
            }
            if(n == 2)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"AB"<<endl;
            }
            }
            if(n == 3)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"ABC"<<endl;
            }
            }
            if(n == 4)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"ABCD"<<endl;
            }
            }
            if(n == 5)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"ABCDE"<<endl;
            }
            }
            if(n == 6)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"ABCDEF"<<endl;
            }
            }
            if(n == 7)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"ABCDEFG"<<endl;
            }
            }
            if(n == 8)
            {
            for(int i = 1;i<=n;i++)
            {
            cout<<"ABCDEFGH"<<endl;
            }
            }
            if(n == 9)
            {
            for(int i = 1;i<n;i++)
            {
            cout<<"ABCDEFGHI"<<endl;
            }
            }
            return 0;
            }
            
            "已AC,放心食用~"
            
            • 1

            信息

            ID
            972
            时间
            1000ms
            内存
            64MiB
            难度
            1
            标签
            递交数
            75
            已通过
            58
            上传者