import Data.Char

solver::Int->Int->String->String
solver a b s = let (as,h:bs)  = splitAt a s in
               let bo = (and (map isDigit as))&&(and (map isDigit bs))&&(h=='-')&&(length bs == b) in
               if bo then "Yes\n" else "No\n"

main::IO()
main=do
  abc<-getLine
  let a:b:[]=map read (words abc)
  s<-getLine
  putStr (solver a b s)