A,B = map(int,raw_input().split())

S = raw_input()

data = [str(i) for i in range(10)]

mozi = 'Yes'
if S[A] == '-':
    for i in range(A+B+1):
        if i == A:
            continue
        if S[i] not in data:
            mozi = 'No'
else:
    mozi = 'No'

print mozi