Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/neetcode-gh/leetcode
/ getAndPopLastOperand
Function
getAndPopLastOperand
go/0150-evaluate-reverse-polish-notation.go:26–32 ·
view source on GitHub ↗
(stack []int)
Source
from the content-addressed store, hash-verified
24
}
25
26
func
getAndPopLastOperand(stack []int) (int, int, []int) {
27
a := stack[len(stack)-2]
28
b := stack[len(stack)-1]
29
stack = stack[:len(stack)-2]
30
31
return
a, b, stack
32
}
Callers
1
evalRPN
Function · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected