Dynamic Programming

Algorithms

Regular Expression Matching

Given an input string s and a pattern p, implement regular expression matching with support for '.' and '*'.

Read
Algorithms

Validating K-Palindromes

Given a string s and an integer k, find out if the given string is a k-palindrome or not. A string is a k-palindrome if it can be transformed into a palindrome by removing at most k characters from it.

Read
Algorithms

Maximum Profit from K Transactions

You have an array for which the i-th element is the price of a given stock on day i. Design an algorithm to find the maximum profit. You may complete at most k transactions.

Read
Algorithms

Partitioning an Array into K Equal Sum Subsets

Given an array of integers nums and a positive integer k, find whether it's possible to divide this array into k non-empty subsets whose sums are all equal.

Read
Algorithms

Minimum Palindromic Partitions

Given a string, split it into as few strings as possible such that each string is a palindrome.

Read