[GCOI Round #1 C] Brackets
题目描述
Mr Aoligei was playing with a string \(s\) written in the computer. The string has brackets and letters inside which he thought it was funny. He likes the string. Then, a hacker hacked his computer. The string was damaged, and he needs to find out How many pairs of brackets are in his string in order to find his string.
Note: "()" is a pair of brackets, but ")(" is not.
输入格式
Input is given from Standard Input in the following format:
\[{\large s}\]
输出格式
print the number of pairs of brackets in the string.
输入输出样例
Input #1
(o)8<))
Output #1
1