DotNetGnat
Programmer
Hi Guys,
I am trying to come up with an algorithm that takes two input strings "L" and "R" and an int n that tells number of combinations.
if n is 1, the result should be L, R
if n is 2, the result should be LL, LR, RL, RR
if n is 3, the result should be LLL, LLR, LRL, LRR, RRL, RRR
and so on...and preferally oredered as shown above...
any suggestions or ideas are welcome...
Thanks
-DNG
I am trying to come up with an algorithm that takes two input strings "L" and "R" and an int n that tells number of combinations.
if n is 1, the result should be L, R
if n is 2, the result should be LL, LR, RL, RR
if n is 3, the result should be LLL, LLR, LRL, LRR, RRL, RRR
and so on...and preferally oredered as shown above...
any suggestions or ideas are welcome...
Thanks
-DNG