print("YNeos"[int(input()) != 2*input().count("(")::2])