题解
2025-04-05 20:12:43
发布于:四川
0阅读
0回复
0点赞
6 6 6 题解 6 6 6
#include <bits/stdc++.h>
using namespace std;
int n,a[105][105];
bool x=true;
int main(){
cin>>n;
for(int i=1;i<=n;i++){
for(int j=1;j<=n;j++){
cin>>a[i][j];
}
}
for(int i=1;i<=n;i++){
for(int j=1;j<=n;j++){
if(i<j && a[i][j]!=0){
x=false;
}
}
}
if(x){
cout<<"YES";
}else{
cout<<"NO";
}
return 0;
}
这里空空如也
有帮助,赞一个