a,b = map(int,input().split())
s = input()
if s[a] == "-":
    s = s[0:a] + s[a:a+b+1]
    for i in s:
        if i == "-":
            print("No")
            exit()
    print("Yes")
else:
    print("No")