MCPcopy Create free account
hub / github.com/austingebauer/go-leetcode / climbStairs

Function climbStairs

climbing_stairs_70/solution.go:3–6  ·  view source on GitHub ↗
(n int)

Source from the content-addressed store, hash-verified

1package climbing_stairs_70
2
3func climbStairs(n int) int {
4 memo := make([]int, n)
5 return exploreStairs(n, 0, memo)
6}
7
8func exploreStairs(n int, c int, memo []int) int {
9 if c > n {

Callers 1

Test_climbStairsFunction · 0.85

Calls 1

exploreStairsFunction · 0.85

Tested by 1

Test_climbStairsFunction · 0.68