main :: IO ()
main = do
  [a, b] <- map read . words <$> getLine
  s <- getLine
  let validLength = length s == a + b + 1
  let validHyphen = s !! a == '-'
  let validChar = not (any (not . (`elem` "0123456789")) (take a s ++ drop (a + 1) s))
  putStrLn $ if validLength && validHyphen && validChar then "Yes" else "No"