Hmm?
I can't see a clear solution using MODE(), and I'm not entirely sure it is the best approach.
In addition to the previous post ...
This array in D7
=INDEX(F6:Q6,1,MODE(IF(--(ISTEXT(F6:Q6))*--(F6:Q6<>C6),MATCH(F6:Q6,F6:Q6,0))))
and this array in D8
=INDEX(F7:Q7,1,MODE(IF(--(ISNUMBER(F7:Q7))*--(F7:Q7<>C7),MATCH(F7:Q7,F7:Q7,0))))
However MODE() will not recognise unique cell values, i.e. the values will have to appear more than once to be recognised.
If there is no duplication returned MODE() will return #N/A.
This isn't perhaps ideal, but might well serve your purpose.
To better understand the returned result, change the value in row 7 (yellow cells) to either 11, or 15.
See this workbook
Bookmarks