Random Team Generator allowing Duplicates on separate teams

b_fruge

New Member
Joined
Aug 25, 2010
Messages
14
Hello: I am working a rodeo benefit that allows people to enter up to 2 times for an event. I need to have all of the members randomly assigned to teams of 4 without pairing them with themselves since they can be on 2 teams. I will have all names in Column A, and the number of teams will be dependent on the number of entries (not set amount).
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
Name
Team
Alan
1
Alan
2
Cain
1
Dana
1
Eric
1
Fran
2
Gary
2
Gary
3
Ivan
2
Jane
3
Kent
3
Leah
3
Mark
4
Nina
4
Otto
4
Otto
5
Quin
4
Rene
5
Seth
5
Tina
5
Ulis
6
Vera
6

<tbody>
</tbody>
Sort the names in alphabetical order.

In B2, enter 1

In B3 and copy down,

=IF(A3=A2, B2+1, MATCH(TRUE, FREQUENCY(B$2:B2, ROW(A$1:A1)) < 4, 0))

The formula MUST be confirmed with Ctrl+Shift+Enter instead of just Enter.
 
Last edited:
Upvote 0
This works great, and I can definitely use it - I wanted to ask before finalizing if there was a way to randomize team assignments. This seems to place them on teams alphabetically by sorting - Once again, not a big deal, just wanted to see if that was an option here.
 
Upvote 0
NameTeam
Alan1
Dana1
Otto1
Ivan1
Jane2
Quin2
Cain2
Gary2
Nina3
Fran3
Ulis3
Tina3
Seth4
Eric4
Rene4
Otto4
Gary5
Alan5
Alan6
Mark5
Leah5
Vera6



<colgroup><col style="width: 37pt;" span="2" width="49">
<tbody>


</tbody>

=MAX(MATCH(TRUE, FREQUENCY(B$2:B2, ROW(A$1:A1)) < 4, 0), IFERROR(LOOKUP(2, 1/(A$1:A2=A3), B$1:B2) + 1, 0))
 
Upvote 0
Thank you for your help - I really appreciate it - That works better without the sort, although it still assigns group numbers based on which order the names are in. However, I can and will use it to meet our needs. Once again, thanks!
 
Upvote 0
You're welcome.

although it still assigns group numbers based on which order the names are in.
Then randomize the order of the names ...
 
Upvote 0

Forum statistics

Threads
1,221,310
Messages
6,159,176
Members
451,543
Latest member
cesymcox

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top