
A,B = input().split()
S = input()

ans = ""

if len(S) > int(A)+int(B)+1 or len(S) < int(A)+int(B)+1 :
    ans = "No"

elif S[int(A)] == "-":
    S[int(A)] == 0
    for i in range(int(A)+int(B)+1):
        if S[i].isdigit():
            ans = "Yes"
        else:
            ans = "No"

else:
    ans = "No"

print(ans)
