Skip to content

Commit 27b802b

Browse files
committed
Fixed a bug in permutations_of_word.py
1 parent d9da92f commit 27b802b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

data_structures/array/permutations_of_word.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ def permutation(lst):
66
l = []
77
for i in range(len(lst)):
88
m = lst[i]
9-
rem_lst = lst[:i] + lst[i+i:]
9+
rem_lst = lst[:i] + lst[i+1:]
1010
for p in permutation(rem_lst):
1111
l.append([m] + p)
1212
return l

0 commit comments

Comments
 (0)