Hey all

Yet another noob question from me

I have the following array

`int row [12] = {20, 30, 37, 50, 67, 83, 100, 117, 133, 167, 200, 233};`

and a value

`int val`

Now I would like to compare the value to the array and find the best match for this, and read this out into a result integer.

`int result`

The readout should be the array position, and not the array value..

To clarify. if my "val" is 90, the one closest to this is 83 and this is in "row [5]". Therefore the value of "result" should be 5