a,b = map(int,input().split())
L = list(input())
c = L[a]
l = len(L)
ok = 0
if c == "-":
    ok = 1
    L.pop(a)
else:
    print("No")
    exit()
if len(L) == a+b:
    ok = 1
else:
    print("No")
    exit()
for i in range(len(L)):
    if str(L[i]).isnumeric() == True :
        print(i)
        ok =1
    else:
        ok = 0
        break

if ok:
  print("Yes")
else:
  print("No")