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

count=0
for i in range (10**A):
    if S[0:A]==str(i):
        count+=1
if S[A]=='-':
    count+=1
for j in range (10**B):
    if S[A+1:A+B]==str(j):
        count+=1

if count==3:
    print ('Yes')
else:
    print ('No')