import sys
def no():
    print("No")
    sys.exit()
a,b=map(int,input().split())
s=input()
num=[str(i) for i in range(1,10)]
if len(s)==a+b+1:
    for i in range(a):
        if s[i] not in num: no()
    if s[a]!="-": no()
    for i in range(a+1,a+b+1):
        if s[i] not in num: no()   

else: no()

print("Yes")