MCPcopy Index your code
hub / github.com/neetcode-gh/leetcode / isOperation

Function isOperation

javascript/0150-evaluate-reverse-polish-notation.js:10–10  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

8 while (1 < tokens.length) {
9 /* Time O(N) */
10 const isOperation = () => tokens[index] in OPERATORS;
11 while (!isOperation()) index++; /* Time O(N) */
12
13 const value = performOperation(tokens, index);

Callers 1

evalRPNFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected