# the number that appears most or least

1. ## the number that appears most or least

the number that appears most/least

2. ## Re: the number that appears most or least

Most frequent is MODE, so =MODE(B1:B16). With conditions, you could use =AGGREGATE(13,6,B1:b16/(B1:B16>=6)/(B1:B16<=7)), but I prefer avoiding Magic Numbers for readability and maintainability, so there's also array formulas like =MODE(IF((B1:B16>=6)*(B1:B16<=7),B1:B16). Note, however, that there are 4 instances of 5.1 and 5.2, but 5.1 appears first in B1:B16, so Excel returns it as the mode.

For least occurring number, there are 5 numbers which appear only once. If you want the first of these, try =INDEX(B1:B16,MATCH(1,COUNTIF(B1:B16,B1:B16),0)). To add conditions, use COUNTIFS and add those conditions as additional arguments.

3. ## Re: the number that appears most or least

Hi,
you can use the frequency function for the most option.
regarding the least - you have multiple answers, since there are several numbers numbers that appear only once and can comply with your condition.
so what answer are you expecting to see if case of multiple results?

D3
``Please Login or Register  to view this content.``
E3:
``Please Login or Register  to view this content.``
F3
``Please Login or Register  to view this content.``