Tag: dynamic programming
You are given coins of different denominations and a total amount of money amount. Write a function to compute the fewest number of coins that you need to make …
Given a string, your task is to count how many palindromic substrings in this string. The substrings with different start indexes or end indexes are counted as different substrings …
A kangaroo is at one side of the river. There are N springs in the river, each is separated 1 meter, like this: K| . . . . . …
Given an integer N, find out the number of method to sum up to N by integers given the following requirements: Natural Numbers (Postive Integers) need to be strictly …
Given a string S and a character C, return an array of integers representing the shortest distance from the character C in the string. Example: Input: S = “loveleetcode”, …