Hi Excel SuperUsers,

I have been struggling with creating custom patterns based on frequency/ duration, priority as inputs....

For example let's say we have 4 letters: A, B, C, D.

Let's say that C has priority and all have frequency/duration of 1. Then I want to output the following:

C,A,C,B,C,D,C,A,C,B,C,D...etc...

Let's say that C has priority and a duration of 2 and the rest have freq./duration of 1. Desired output would be:

CC,A,CC,B,CC,D,CC,A,CC,B,CC,D...etc...

Let's say that C has priority and freq/duration of 3 while the rest have no priority but D has duration of 4 and the rest a duration of 1. Desired output would be:

CCC,A,CCC,B,CCC,DDDD,CCC,A,CCC,B,CCC,DDDD,CCC,A....etc....

Let's say that C & A both have priority. C has freq/duration of 2 and A has freq/duration of 3, D does not have priority and has duration of 4 while B has duration of 1 (no priority as well). Desired output would be:

CC,B,AAA,DDDD,CC,B,AAA,DDDD,CC,B

I have been playing with array function (index, row, rows, match, mod, countif, etc..) but can't seem to get it straight.

Is there a good source to get more educated on it? Can you provide any insight or solution?

Thanks

T