View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Ragdyer
 
Posts: n/a
Default How do I sort randomly a list of 22 numbers

You can create a random, without replacement list, without sorting or using
code.

In an out-of-the-way area of your sheet, say Column Z, enter the Rand()
function as far down as the amount of numbers you wish to draw from.

In your case, in Z1 enter:
=RAND()
And copy down to Z22.

NOW, if you wish to *just* use the numbers 1 to 22, enter this formula
anywhe

=INDEX(ROW($1:$22),RANK(Z1,$Z$1:$Z$22))
And copy down 22 rows.

You can use *any* 22 numbers *and/or* letters if you wish, by entering the
list to pick from in say A1 to A22, and then use this formula:

=INDEX($A$1:$A$22,RANK(Z1,$Z$1:$Z$22))
And copy down 22 rows.

Each hit of <F9 will produce a new random order.
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"Deal or No Deal game simulation" <Deal or No Deal game
wrote in message
...
I have an array of 22 numbers from 1 to 22 in a column. By pressing F9 i

want
to be able to change their position randomly in the column. How can I do
this? In essence the numbers selected are not random number but what want

to
be random is the numbers position within the range of cells