Searching numbers in Worksheet

J

Johncobb45

In my Worksheet I have 80 columns (80) numbers with over 100 rows.
All numbers (1-80) in each row are mixed.
I picked 20 random numbers between 1 and 80.
My conditional formating formula marks in each row 20 numbers that
picked.
The conditional formating formula is: =MATCH(A1,$CC$1:$CC$20,0)
I have divided the worksheet in to 2 even parts (40 numbers/columns o
each side).
I want to know if it is possible to make conditional formating formul
to show me how many numbers that I have picked is in first 40 cells an
how many numbers is in second lot of 40 cells in the same row.
I would like the formula to disply the result at the end of each row.
Is it possible?
If you need more explanations please let me know.
Thanks in advance for your help.
Joh
 
B

Biff

Hi!

Try this:

For the first 40 columns:

=SUMPRODUCT(COUNTIF(A1:AN1,CC$1:CC$20))

For the second 40 columns:

=SUMPRODUCT(COUNTIF(AO1:CB1,CC$1:CC$20))

Copy down as needed.

Biff
 
B

Biff

P.S.

I'm assuming there are no duplicate numbers in a row or duplicate random
numbers.

Biff
 
J

Johncobb45

Thank you Biff.
Well done.
It works well.
I appreciate your help.
Best Regards,
John
 
J

Johncobb45

I have one more question.
Is it possible to fill random numbers in a column?
I want excel to enter for me 20 random numbers (between 1 and 80) in t
a column.
Is it possible to do it with one click instead entering them manual
one by one, for example by clicking or filling just one top cell?
If you need more explanations please let me know.
Regards,
Joh
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top