I at first (weakly) tried to create a formula approach. But after rolling it over in my mind a couple minutes I realized that would be too complicated.
So... I just worked out the variations of the sequencing starting with 1 and then copied the section of results to sequence starting with 2. The I did a find and replace in the spreadsheet so that all 2's AFTER the first column [C1] were found and replaced by 1. Thus no complicated formula. In most spreadsheet application a find/replace literally takes a few seconds [unless you have gigantic data field]
How did I create the first 1 range of sequence?
If you look I copied 1 down 120 times, 2 down 120 times, 3 down a 120 times, etc. So now we have 1 --120 times, 2--120 times, etc. So now I am confident that I have 720 rows [120 X 6 = 720].
So then I went back up to the 1 sequence and starting in C2 I copied 2 down 24 times. Why 24 times? We know NON 2's in the 1- 6 range are 3,4,5,6 so this is factorial of 4 or 4! The result of factorial of 4! = 24.
Then in column C2 I copied 3 down 24 time, 4 down 24 times, 5 down 24 times and 6 down 24 times . So now in C2 I have 24 sequences of 2's, 24 sequences of 3's, 24 sequences of 4's, 24 sequences of 5's and 24 sequences of 6's. So now I have 24 cells each of 5 numbers (2,3,4,5,6) or 24 X 5=120.
So then I went back up to the 1 sequence and starting in C3 I copied 3 down 6 times. Why 6 times? We know NON 1's and NON 2's in the 1- 6 range are 4,5,6 so this is factorial of 3 or 3! The result of factorial of 3! = 6.
Then in column C3 I copied 3 down 6 times, 4 down 6 times, 5 down 6 times and 6 down 6 times . [24 rows total]
Now I am row 25 which started the 1 3 sequence so I copy 2 down 6 times, 4 down 6 times, 5 down 6 times and 6 down 6 times. [24 rows total]
Now I am row 49 which starts the 1 4 sequence so I copy 2 down 6 times, 3 down 6 times, 5 down 6 times and 6 down 6 times. [24 rows total]
Now I am row 73 which starts the 1 5 sequence so I copy 2 down 6 times, 3 down 6 times, 4 down 6 times, and 6 down 6 times. [24 rows total]
Now I am in row 97 which starts the 1 6 sequence so I copy 2 down 6 times, 3 down 6 times, 4 down 6 times and 5 down 6 times. [24 rows total]
So now in I have 5 instances of 24 rows 5 X 24 =120.
Then I went back up top to first row and column C4, and performed 2 sequences of each number [Except not 1's which are in C1] This was probably the trickiest column so it would take me forever to type in words how I typed the data into the spreadsheet. But I will attempt to describe it at high level and hope it is reasonable description. Since I knew it had to be the same number twice I just would type a number then go downwards to the next cell and type the same number. Always making sure to look to the left so as not to duplicate the numbers in C1, C2 and C3. So as I am typing along:
1234
1234
1235
1235
Just kept going down in similar manner and paying attention to when the sequence in C1 and C2 changed.
I admit C5 and C6 were also sort of tricky - so just the easiest way to describe how I did it was just patience and being careful. It actually looks a lot more difficult then it was for me to perform the steps - I just don't know how to easily tell you that I made sure that I had no errors.
So once I was certain I had all the correct variations for rows 1 - 120 - everything starting with 1. I took Cells ROW1-ROW120 Columns C2-C6 [purposely EXCLUDING C1] and pasted the cells into ROWS 121-240 C2-C6[again purposely EXCLUDING C1], Then did Find and Replace. Found all 2's in this section and replaced with 1's. [Replaced 2's in this section because now 2 is in C1]
So...your next question (anticipating it!) is HOW did I make sure there was no errors or repetition. Welllllll I built a nested IF statement
Or in normal terms I created 7 columns of calculations. The first column had calculation if Cell Row1 C1 has 1 then 1X1, if 2 then 2X2 if 3 then 3X3 if 4 then 4X4 if 5 then 5X5 if 6 then 6X6. I then copied that formula to the next five columns so I have 6 columns of same formula. Then in the seventh column I have the six prior columns added together [for those that are familiar with spreadsheets - yes I realize there is a different way I could have done these calculations - just was trying to make some of my steps easier and easier to try to describe here].
Example Row 1 1X1 = 1; 2X2=4; 3X3=9; 4X4=16; 5X5=25, 6X6=36
1+4+9+16+25+36=91. If I did everything right in columns C1 through C6 then the answer HAS to be 91. So 91 becomes my error checker.
Example Row 2 1X1 =1; 2X2=4; 3X3=9; 4X4=16; 6X6=36, 5X5=25
1+4+9+16+36+25=91
I made sure each 720 rows had result of 91 through this formula
I know this sounds like a lot of work but actually it sounds worse then it turned out to be.
Trying to describe in words how I performed data manipulation is actually trickier then performing the actual steps - so hopefully made some degree of sense.