For example, I have an array

```
["red", "green", "blue", "purple"]

```

There can be any amount of entries in this array.
Using this array I want to create a list of possible combinations but never duplicating a combination

For example, the above array will result in

```
red,green,blue,purple
red,green,purple,blue
red,blue,green,purple
red,blue,purple,green
red,purple,blue,green
red,purple,green,blue

green,red,blue,purple
green,red,purple,blue
green,blue,red,purple
green,blue,purple,red
green,purple,blue,red
green,purple,red,blue

blue,red,green,purple
blue,red,purple,green
blue,green,red,purple
blue,green,purple,red
blue,purple,green,red
blue,purple,red,green

purple,red,green,blue
purple,red,purple,blue
purple,green,red,blue
purple,green,blue,red
purple,blue,green,red
purple,blue,red,green

```

I am new to recursion and I havent quite gripped how to accomplish this with it,