Amazon Interview Question

Create permutations of a string