broncos347
Active Member
- Joined
- Feb 16, 2005
- Messages
- 291
- Office Version
- 365
- Platform
- Windows
I have four columns which I are labelled as Performance (Column A), Safety (Column B), Probability (Column C) and Effect (Column D) and in each one of those columns there could be a number from between 1 and 5.
Is there a formula or a bit of VBA which would be able to generate every permutation of each line of numbers for each of the columns, as shown in the example below?
Is there a formula or a bit of VBA which would be able to generate every permutation of each line of numbers for each of the columns, as shown in the example below?
permutations.xlsm | ||||||
---|---|---|---|---|---|---|
A | B | C | D | |||
1 | Performance | Safety | Probability | Effect | ||
2 | 1 | 1 | 1 | 1 | ||
3 | 1 | 2 | 1 | 1 | ||
4 | 1 | 2 | 2 | 1 | ||
5 | 1 | 2 | 3 | 1 | ||
6 | 1 | 2 | 4 | 1 | ||
7 | 1 | 2 | 5 | 1 | ||
8 | 1 | 2 | 2 | 2 | ||
9 | 1 | 2 | 2 | 3 | ||
10 | 1 | 2 | 2 | 4 | ||
11 | 1 | 2 | 2 | 5 | ||
12 | 1 | 2 | 3 | 2 | ||
13 | 1 | 2 | 3 | 3 | ||
14 | 1 | 2 | 3 | 4 | ||
15 | 1 | 2 | 3 | 5 | ||
16 | 1 | 2 | 3 | 3 | ||
17 | 1 | 2 | 3 | 4 | ||
18 | 1 | 2 | 3 | 5 | ||
19 | 1 | 2 | 4 | 2 | ||
20 | 1 | 2 | 4 | 3 | ||
21 | 1 | 2 | 4 | 4 | ||
22 | 1 | 2 | 4 | 5 | ||
23 | 1 | 2 | 5 | 2 | ||
24 | 1 | 2 | 5 | 3 | ||
25 | 1 | 2 | 5 | 4 | ||
26 | 1 | 2 | 5 | 5 | ||
Sheet1 |