LeetCode 903: Valid Permutations for DI Sequence
A clear explanation of counting valid DI permutations using dynamic programming and prefix sums.
5 notes
A clear explanation of counting valid DI permutations using dynamic programming and prefix sums.
A clear explanation of solving Largest Time for Given Digits by checking all permutations of four digits.
A clear explanation of Next Greater Element III using the next permutation algorithm on the digits of an integer.
A clear explanation of the Palindrome Permutation II problem using character counts and backtracking over half of the palindrome.
A clear guide to finding the kth permutation sequence using factorial blocks instead of generating all permutations.