← ALL NOTES
Array

3567. Minimum Absolute Difference in Sliding Submatrix

Given a matrix grid and k. For each k×k submatrix, find the minimum absolute difference between two distinct values in it. Return the matrix of these minima, of size (m−k+1)×(n−k+1).

Loading…