program proB
  implicit none
  integer i,j,a,b
  character s*9,check*10

  read(*,*) a,b
  read(*,*) s

  check='0123456789'
  do i=1,a+b
     if(i==a+1) then
        if(s(i:i)=='-') then
           cycle
        else
           write(*,*) 'No'
           stop
        end if        
     else if(s(i:i)=='0' .or. s(i:i)=='1' .or. s(i:i)=='2' .or. s(i:i)=='3' &
          .or. s(i:i)=='4' .or. s(i:i)=='5' .or. s(i:i)=='6' .or. s(i:i)=='7' &
          .or. s(i:i)=='8' .or. s(i:i)=='9') then
        cycle
     else
        write(*,*) 'No'
        stop
     end if
  end do

  write(*,*) 'Yes'
  

end program proB
