- 【GESP202303C++二级】画三角形
h
- 2025-1-12 16:54:57 @
#include<bits/stdc++.h>
using namespace std;
int n;
int main(){
char a='A';
scanf("%d",&n);
for(int i=1;i<=n;i++){
for(int j=1;j<=i;j++){
printf("%c",a);
a++;
if(a>'Z') a='A';
}
printf("\n");
}
return 0;
}
0 comments
No comments so far...
Information
- ID
- 2541
- Time
- 1000ms
- Memory
- 256MiB
- Difficulty
- 7
- Tags
- # Submissions
- 16
- Accepted
- 9
- Uploaded By