Fix backtrack time complexity (#965)

* Update backtracking/all_permutations.py
This commit is contained in:
Erfan Alimohammadi 2019-07-06 20:01:52 +04:30 committed by GitHub
parent 781b7f86e7
commit 69bed59036
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2,7 +2,7 @@
In this problem, we want to determine all possible permutations In this problem, we want to determine all possible permutations
of the given sequence. We use backtracking to solve this problem. of the given sequence. We use backtracking to solve this problem.
Time complexity: O(n!), Time complexity: O(n! * n),
where n denotes the length of the given sequence. where n denotes the length of the given sequence.
''' '''