input() s = input() print('Yes' if s.count('(') == s.count(')') else 'No')