a,b = list(map(int,input().split()))
s =input()
for i in range(a+b+1):
    if i != a:
        if int(s[i])>=10:
            print("No")
            break
            
    else:
        if s[i] !='-':
            print('No')
            break
else:
    print('Yes')