| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 68080 | 安一宸 | 放大的X | C++ | Accepted | 100 | 10 MS | 256 KB | 376 | 2023-02-02 13:52:36 |
#include<bits/stdc++.h> using namespace std; int a,n; char b[100][100]; int main(){ cin>>n; while(n--){ cin>>a; if(a==1){ cout<<"X"<<endl; }else{ for(int i=0;i<a;i++){ for(int j=0;j<a;j++){ if(i==j||i==a-j-1) b[i][j]='X'; else b[i][j]=' '; cout<<b[i][j]; } cout<<endl; } } cout<<endl; } return 0; }