A,B=map(int,input().split())
S=input()
f=True
if len(S)!=A+B+1:
    f=False
num=[chr(i) for i in range(ord('0'),ord('9')+1)]
for i,c in enumerate(S):
    if (i!=A and c not in S) or (i==A and c!='-'):
        f=False
print('Yes' if f else 'No')