def judge(S,A,B):
  a = list(S)
  front = a[:A]
  back = a[A+1:]
  for i in range(A):
    if not type(front[i])==int:
      print("No")
      return
  for j in range(B):
    if not type(back[j])==int:
      print("No")
      return
  if not a[A]=="-":
    print("No")
    return
  print("Yes")
  
A,B = map(int,input().split())
S = input()
judge(S,A,B)