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

num = list(map(str, range(0, 10)))

ans = 'Yes'

if s[a] == '-':
    for x in range(a):
        if s[x] not in num:
            ans = 'No'
            break
    for x in range(a+1, b):
        if s[x] not in num:
            ans = 'No'
            break
else:
    ans = 'No'

print(ans)
