MCPcopy Create free account
hub / github.com/TheAlgorithms/Go / Max

Function Max

dynamic/knapsack.go:14–16  ·  view source on GitHub ↗

Max function - possible duplicate

(a, b int)

Source from the content-addressed store, hash-verified

12
13// Max function - possible duplicate
14func Max(a, b int) int {
15 return int(math.Max(float64(a), float64(b)))
16}
17
18// Knapsack solves knapsack problem
19// return maxProfit

Callers 6

KnapsackFunction · 0.85
LongestCommonSubsequenceFunction · 0.85
CutRodRecFunction · 0.85
CutRodDpFunction · 0.85
lpsRecFunction · 0.85
LpsDpFunction · 0.85

Calls 1

MaxMethod · 0.65

Tested by

no test coverage detected