input: Write a python function to generate all permutations of a string.
  assert permutation("abc") == ['abc', 'acb', 'bac', 'bca', 'cab', 'cba']
  assert permutation("ab") == ['ab', 'ba']
  assert permutation("a") == ['a']
output: def permutation(s):
      if len(s) == 1:
          return [s]
      perms = []
      for i, char in enumerate(s):
          for perm in permutation(s[:i] + s[i+1:]):
              perms.append(char + perm)
      return perms