Given a string `s` representing a valid arithmetic expression, evaluate it and return the result as an integer.
The expression may contain:
- Non-negative integer numbers
- `+` and `-` operators (including **unary** minus, e.g. `"-(2 + 3)"`)
- Parentheses `(` and `)`
- Spaces
You must **not** use any built-in expression evaluator (such as `eval`).
Example 1
Input:s = "1 + 1"
Output:2
Example 2
Input:s = " 2-1 + 2 "
Output:3
Example 3
Input:s = "(1+(4+5+2)-3)+(6+8)"
Output:23
Constraints
- 1 <= s.length <= 3 * 10^5
- s consists of digits, '+', '-', '(', ')', and ' '.
- s represents a valid expression.
- '+' is never used as a unary operator.
- Every number and the result fit in a signed 32-bit integer.