include [HTML_REMOVED]
using namespace std;
const int SIZE = 50;
int n1, m1, n2, m2, a[SIZE][SIZE], b[SIZE][SIZE];
int main(){
int i, j, k1, k2;
bool good, haveAns;
cin>>n1>>m1;
for (i = 1; i <= n1; i)
for (j = 1; j <= m1; j)
cin>>a[i][j];
cin>>n2>>m2;
for (i = 1; i <= n2; i)
for (j = 1; j <= m2; j)
①;
haveAns = false;
for (i = 1; i <= n1 - n2 + 1; i)
for (j = 1; j <= ②; j){
③;
for (k1 = 1; k1 <= n2; k1)
for(k2 = 1; k2 <= ④; k2) {
if (a[i + k1 - 1][j + k2 - 1] != b[k1][k2])
good = false;
}
if (good) {
cout<<i<<' '<<j<<endl;
⑤;
}
}
if (!haveAns)
cout<<"There is no answer"<<endl;
return 0;
}
填空位置 ①:
cin>>b[i][j]
填空位置 ②:
m1 - m2 + 1
填空位置 ③:
good = true
填空位置 ④:
m2
填空位置 ⑤:
haveAns = true