Picking Random Names
Posted
by Jasl
on Stack Overflow
See other posts from Stack Overflow
or by Jasl
Published on 2010-06-17T05:05:58Z
Indexed on
2010/06/17
5:13 UTC
Read the original article
Hit count: 276
I saw an interesting post sometime back but with no solution. Trying luck here:
There is a table which contain 10 names (U1, U2, U3..and so on). I have to choose 5 names everyday, and display one as the Editor and 4 as Contributors
While selecting the random names, I have to also consider that if one user is selected as Editor, he cannot become editor again till everyone got their chance.
The output should look similar to the following:
Editor Cont1 Cont2 Cont3 Cont4
20-Jun U1 U8 U9 U3 U4
21-Jun U7 U2 U5 U6 U10
22-Jun U3 U4 U9 U2 U8
23-Jun U4 U8 U3 U5 U2
and so on..
© Stack Overflow or respective owner