dp

package
v0.0.0-...-bced520 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 7, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IntegerBreak

func IntegerBreak(n int) int

func LengthOfLIS

func LengthOfLIS(nums []int) int

LengthOfLIS returns the length of the longest strictly increasing subsequence.

func LongestPalindrome

func LongestPalindrome(s string) string

LongestPalindrome return the longest palindromic substring in s

func MaxSubarraySum

func MaxSubarraySum(nums []int) int

MaxSubarraySum returns max sum of subarray.

func MinDistance

func MinDistance(word1 string, word2 string) int

MinDistance returns the minimum number of operations required to convert word1 to word2.

func MinPathSum

func MinPathSum(grid [][]int) int

MinPathSum returns minimizes the sum of all numbers along path that from top left to bottom right

func NthUglyNumber

func NthUglyNumber(n int) int

NthUglyNumber returns the nth ugly number. Ugly number is a positive number whose prime factors only include 2, 3, and/or 5

func UniquePaths

func UniquePaths(m int, n int) int

func UniquePathsWithObstacles

func UniquePathsWithObstacles(obstacleGrid [][]int) int

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL