View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Patrick Molloy Patrick Molloy is offline
external usenet poster
 
Posts: 1,049
Default find where a number belongs in a series of numbers

the MATCH function will do that

=MATCH(D3,A1:A500,TRUE)

as your numbers are sorted, TRUE will return index the number 'nearest' to
the one you're looking for.

so if in A you had 39 40 41 42 43 and you did a match on 41.4 then answer
would be 3 .... as the 3rd item, 41 is the closest to, and less than your
query


"greg" wrote in message
...
Is there an easy excel formula that I can use that will find where a
number belongs in a series of numbers.
So for instance
in A1 to A 500 I have random numbers. I can order them lowest to highest.
then I have a new single number.
Lets say it would go between 40 and 41
is there a excel formula that would help me on this?
to make it easy and the right way to do it.
instead of a lot of code?

thanks