#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  cin >> a >> b;
  string s;
  cin >> s;
  string sa = s.substr(0, a);
  string sb = s.substr(a + 1, b);
  if (s[a] == '-') {
    for (int i = 0; i < a; i++) {
      if (!isdigit(sa[i])) {
        cout << "no" << endl;
        return 0;
      }
    }
    for (int i = 0; i < b; i++) {
      if (!isdigit(sb[i])) {
        cout << "no" << endl;
        return 0;
      }
    }
    cout << "yes" << endl;
  } else {
    cout << "no" << endl;
  }
  return 0;
}
