Given two matrices A with n rows and m columns and B with x rows and y columns, check whether B appears in A. Matrix B is said to appear in A if there exists a submatrix in A that is identical to B.
YES
if B appears in A, otherwise print NO
.Input:
3 4 2 2
1 3 4 2
2 6 8 1
2 3 4 5
4 2
8 1
Output:
YES
Pascal's triangle | |
Column sum | |
Appearance | |
Diagonal sum | |
Point coverage | |
Swap operation | |
Spiral matrix | |
Word search | |
Matrix rotation | |
Matrix Zigzag |