Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
307782 黄浙峰老师 【C4-T】拐角V C++ 通过 100 3 MS 256 KB 328 2025-01-04 13:50:27

Tests(1/1):


#include<bits/stdc++.h> using namespace std; int a[500][500]; int main(){ int n,t; cin>>n; for(int i=n;i>=1;i--){ t=1; for(int j=n;j>=1;j--){ a[i][j]=t; if(t<i) t++; } } for(int i=1;i<=n;i++){ for(int j=1;j<=n;j++){ cout<<setw(3)<<a[i][j]; } cout<<endl; } return 0; }


测评信息: