<Ч
Size: a a a
<Ч
VL
VL
<Ч
VL
MN
def permutations(word):
if len(word) == 1:
return [word]
perms = permutations(word[1:])
char = word[0]
result = []
for perm in perms:
for i in range(len(perm) +1):
result.append(perm[:i] + char + perm[i:])
return result
print(permutations('abc'))
MN
E
E
K
MN
K
E
E
E
I
DL
DL
Д
lambda text : self.ui.textBrowser.append(text)
.