#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int a, b;
  cin >> a >> b;
  string s;
  cin >> s;
  if (s.length() != a + b + 1)
    cout << "No" << endl;
  else {
    for (int i = (0); i < (s.length()); ++i) {
      if (i == a) {
        if (s[i] != '-') cout << "No" << endl;
      } else {
        if (s[i] >= '0' && s[i] <= '9') continue;
      }
      cout << "No" << endl;
      return 0;
    }
  }
  cout << "Yes" << endl;
  return 0;
}
