Medium
Given a balanced parentheses string s, compute its score: () is 1, AB is A+B, and (A) is 2*A.
s
()
AB
(A)
Input: s = "()" Output: 1
Input: s = "(())" Output: 2
Input: s = "()()" Output: 2
Input: s = "(()(()))" Output: 6