a, b = map(int, input().split())
S = input()

ans = 'Yes'
if S[a + 1] == '-':
    S = S.replace('-', '', 1)
    for i in S:
        if not i in '1234567890':
            ans = 'No'
else:
    ans = 'No'
    
print(ans)