local a, b = io.read("*n", "*n", "*l")
local s = io.read()
local f = true
for i = 1, #s do
  if i == a + 1 then
    if s:sub(i, i) ~= "-" then f = false break end
  else
    local c = s:sub(i, i):byte()
    if c < 48 or 57 < c then
      f = false
      break
    end
  end
end
print(f and "Yes" or "No")
