import sys

(A,B),S = map(int,input().split()),input()
print("A: ", A)
print("B: ", B)
print("S: ", S)
print("length: ", len(S))

if (len(S) == (A+B+1)) and (S[A] == '-') and (S.count('-') == 1):
    print("yes")
else:
    print("No")
    
