I was going through one of the online courses for Data strudcture and Algorithms. There I saw saw a topic "Delta based two dimensional array search". Which describes below:
- A techinque to search adjoing array elements of four directions in coordinates of two directions.
- Delta value is an array that saves coordinates of four direction in coordinates as well as difference between X and Y.
- Delta value is employed to approach the elements located up down left right side of certain element.
As per m understanding, its basically searching neighbors in four directions of a given array. I found couple of good answers on stack overflow:
More efficient way to check neighbours in a two-dimensional array in Java
Finding neighbours in a two-dimensional array
However I am not clear with the 2nd point "Delta value is an array that saves coordinates of four direction in coordinates as well as difference between X and Y". Can anyone explain what does this point means? Also the stack overflow links that I mentioned above serve the purpose? Thank You