A,B = [int(x) for x in input().split()]
S = input()
flag = True
for ind,i in enumerate(S):
  if(ind!=A):
      if(ord(i)<48 or 57<ord(i):
         flag = False
         break
  else:
      if(i!='-'):
         flag = False
         break
if(flag):
         print('Yes')
else:
         print('No')