Say I have an array of n integers, m, each chosen randomly from the range [x,y].
I also have a window of fixed size [a,b], and smaller than [x,y] such that b-a < x-y.
Starting from an arbitrary window position, can anyone think of a good algorithm to use to determine whether it is possible for the window to be moved such that all elements of m are enclosed within the window?