#include <iostream>
using namespace std;
int  main(){
  int a,b,f=0;
  string s;
  cin >> a >> b >> s;
  if(a+b+1 == s)
    f=1;
  if(s[a+1] != "-")
    f=1;
  if(s.find("-") != 1)
    f=1;
  
  if(f){
    cout << "No" << endl;
  }else{
    cout << "Yes" << endl;
  }
  return 0;
}