I’m tired. This must be simple. wood… for…. trees….
I’m trying to return the position of a specific value in a 2D array.
I have a double array [300][300].
All values contained in it are 0 apart from one which is 255.
How do I write a method to return the [i][j] location of 255?
Thanks in advance.
Simply iterate over all the elements until you find the one that is
255: