解法:
#include<iostream>
#include<vector>
using namespace std;
int arr[100][100];
int main() {int n;int x, y;cin >> n >> x >> y;for (int i = 0; i < n; i++) {for (int j = 0; j < n; j++) {cin >> arr[i][j];}}if (arr[x][y] || arr[y][x])cout << "yes";else cout << "no";return 0;
}