def judge(S,A,B):
  a = list(S)
  front = a[0:A]
  back = a[A+1:A+B+1]
  lst = ["0","1","2","3","4","5","6","7","8","9"]
  for i in range(A):
    if front[i] not in lst:
      print("No1")
      return
            
  for j in range(B):
    if back[j] not in lst:
      print("No")
      return
            
  if a[A]!="-":
    print("No")
    return
  
  print("Yes")
  
A,B = map(int,input().split())
S = input()
judge(S,A,B)