I have this grid and I want to input a xy coordinate into a method that returns the value on the cell
the grid looks like this:
as you see there is a clear pattern of repetition, i was wondering what is the formula that will output the values for this particular distribution.
Basically I’m looking for a formula in which I input ( x = 2, y =2 ) and it returns 9
x=3. y=3 returns 1 etc
I dont want to fill an array or a grid with these values, just the formula that returns the values for this particular distribution
Thanks!