#include <bits/stdc++.h>
using namespace std;

#define all(x) x.begin(), x.end()
#define sz(x) (int)x.size()

typedef long long ll;

const char nl = '\n' ;
const ll MOD = 1e9 + 7;


int main()
{
   ios_base::sync_with_stdio(0); cin.tie(0);
   int a, b;
   string s;
   cin >> a >> b >> s;
   if(a+b+1 != s.size() || s[a] != '-')
   {
      cout << "No" << nl;
      return 0;
   }
   for(int i = 0; i < s.size(); i++)
   {
      if(i == a) continue;
      if(s[i] < '0' || s[i] > '9')
      {
         cout << "No" << nl;
         return 0;
      }
   }
   cout << "Yes" << nl;
   return 0;
   return 0;
}

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(k,i,n) for(ll i=k;i<n;++i)
int main(void){
    ll a,b;
    cin>>a>>b;
    string s;
    cin>>s;
    bool ans=true;
    rep(0,i,a)if(!(s[i]>='0'&&s[i]<='9'))ans=false;
    if(s[a]!='-')ans=false;
    rep(0,i,b)if(!(s[a+1+i]>='0'&&s[a+1+i]<='9'))ans=false;
    if(ans)cout<<"Yes";
    else cout<<"No";
}
