> For the complete documentation index, see [llms.txt](https://liuzhenglaichn.gitbook.io/algorithm/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://liuzhenglaichn.gitbook.io/algorithm/backtracking.md).

# Backtracking

The rough time complexity estimation of a backtracking solution might seem very high, but since there are lots of cases skipped, usually such solution can pass.

## Problems

* [51. N-Queens (Hard)](https://leetcode.com/problems/n-queens/)
* [473. Matchsticks to Square (Medium)](https://leetcode.com/problems/matchsticks-to-square/)
* [1723. Find Minimum Time to Finish All Jobs (Hard)](https://leetcode.com/problems/find-minimum-time-to-finish-all-jobs/)
* [2014. Longest Subsequence Repeated k Times (Hard)](https://leetcode.com/problems/longest-subsequence-repeated-k-times/)

### Subset

* [698. Partition to K Equal Sum Subsets (Medium)](https://leetcode.com/problems/partition-to-k-equal-sum-subsets/)
* [2597. The Number of Beautiful Subsets (Medium)](https://leetcode.com/problems/the-number-of-beautiful-subsets)
