文理学院程序设计在线练习


括号匹配问题

Time Limit: 1 Second(s)    Memory Limit: 32 MB

Total Submission(s): 582   Accepted Submission(s): 263
Problem Description

输入一个由中、小括号组成的字符串。判断其匹配情况。
如果括号可以成功匹配,则输出yes,反之输出no
一直处理到文件结束

Sample Input
()[]
[()]
[(()]]
[(])
Sample Output
yes
yes
no
no