#include <bits/stdc++.h>
#define rep(i,n) for (int i = 0; i < (n); i++)
#define repf(i,a,b) for (int i = (a); i < (b); i++)
#define repi(i,a,b) for (int i = (a); i <= (b); i++)
#define repr(i,a,b) for (int i = (a); i >= (b); i--)
#define all(x) (x).begin(),(x).end()
#define debug(x)  cout << #x << " = " << (x) << endl;
using namespace std;
using uint = unsigned int;
using ll = long long;
using ull = unsigned long long;
using vi = vector<int>;
using vvi = vector<vi>;
using pii = pair<int, int>;
using vc = vector<char>;
using vvc = vector<vc>;
using vs = vector<string>;
using tiii = tuple<int, int, int>;

int main() {
  int A, B; cin >> A >> B;
  string S; cin >> S;
  
  rep(i,A) if(!('0'<=s[i]&&s[i]<='9')) {
    cout << "No" << endl;
    return 0;
  }
  if (s[A]!='-') {
    cout << "No" << endl;
    return 0;
  }
  repi(i,A+1,A+B) if(!('0'<=s[i]&&s[i]<='9')) {
    cout << "No" << endl;
    return 0;
  }
  cout << "Yes" << endl;
}

