提交时间:2025-12-27 17:03:41
运行 ID: 78761
#include<bits/stdc++.h> using namespace std; int main() { int n, tot = 0, cnt = 0; cin>>n; int ls[n][n]; // cout << fixed << setprecision(10) << ce(a); for(int i = 0; i < n; i++){ for(int j = 0; j < n; j++){ int a; cin>>a; ls[i][j] = a; } } for(int x = 0; x < n; x++){ for(int y = 0; y < n; y++){ int flag = 1; for(int z = 0; z < n; z++){ if(ls[x][z] > ls[x][y] || ls[z][y]<ls[x][y]){ flag = 0; } } if(flag == 1){ cout<<ls[x][y]<<" "; } } } return 0; }