[Google Sheet Question] Trying to perform a "snake" report

thp510

Board Regular
Joined
Oct 19, 2015
Messages
110
Office Version
  1. 365
Platform
  1. Windows
I have a list of 5 individuals that I would like to assign using a snake draft (similar to a fantasy football style draft), where the the last person to pick something is the next person to pick. For example, there are 5 people (Kelly, Jon, Bob, Suzie, and Tom) and here's their pick order: Kelly goes 1st, Jon goes 2nd, Bob goes 3rd, Suzie goes 4th, and Tom goes 5th. However, next, Tom goes first, Suzie goes second, etc... Here's the first 16th pick order to show as an example:

1st Pick: Kelly
2nd Pick: Jon
3rd Pick: Bob
4th Pick: Suzie
5th Pick: Tom
6th Pick: Tom
7th Pick: Suzie
8th Pick: Bob
9th Pick: Jon
10th Pick: Kelly
11th Pick: Kelly
12th Pick: Jon
13th Pick: Bob
14th Pick: Suzie
15th Pick: Tom
16th Pick: Tom
...etc...etc... It's the snake method.

I want to create an equation where I can just populate the first 5 names and then drag the rest of the cells down the rows.

1685989796979.png


What equation would I put in cell C8 in Google Sheets to get this to work?

Thanks!
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
Upvote 0
Solution
How about this?

thp510
BCDE
2AccountsAssignmentOrder
31KellyKelly
42JonJon
53BobBob
64SuzieSuzie
75TomTom
86Tom
97Suzie
108Bob
119Jon
1210Kelly
1311Kelly
1412Jon
1513Bob
1614Suzie
1715Tom
1816Tom
1917Suzie
2018Bob
2119Jon
2220Kelly
2321Kelly
2422Jon
2523Bob
2624Suzie
2725Tom
2826Tom
2927Suzie
3028Bob
3129Jon
3230Kelly
Sheet2
Cell Formulas
RangeFormula
B3:B32B3=SEQUENCE(30)
C3:C32C3=INDEX($E$3:$E$7,IF(ISODD(INT(((ROW(C3)-ROW($C$2))-1)/5)+1),MOD((ROW(C3)-ROW($C$2))-1,5)+1,5-MOD((ROW(C3)-ROW($C$2))-1,5)))
Dynamic array formulas.

Thanks, but I'm having problems with placing $C$2. I had to move my rows of data further down so now my header for my columns doesn't start until row 6 (i.e. C6 is where I have the word "Assignment"). How does the equation change? When I changed $C$2 to $C$6 in the equation I got a different person showing up (it was Tom instead of Kelly on cell C7.
 
Upvote 0
I'll be away from my computer for a couple of hours so I can't really mess with it.

But, the idea is that the header cell will have the absolute reference and the cell below it will be relative. So, ot looks like it should be $C$6 and then change C3 to C7. The idea is to, for the first cell anyway, to start counting at 1. It's subtraction, so whatever you need to do to return a 1, then as you drag down it will increment up by 1 each time.
 
Upvote 1
I'll be away from my computer for a couple of hours so I can't really mess with it.

But, the idea is that the header cell will have the absolute reference and the cell below it will be relative. So, ot looks like it should be $C$6 and then change C3 to C7. The idea is to, for the first cell anyway, to start counting at 1. It's subtraction, so whatever you need to do to return a 1, then as you drag down it will increment up by 1 each time.
Ahh! That make sense. I just redid it your way and it works! Thank you!
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,327
Members
452,635
Latest member
laura12345

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