#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  string s;
  cin >> a >> b >> s;
  bool f = true;
  for (int i = 0; i < a; i++) {
    if (!isdigit(s[i])) {
    }
  }
  if (!('-' == s[a])) {
    f = false;
  }
  for (int i = a + 1; i < b; i++) {
    if (!isdigit(s[i])) {
      f = false;
    }
  }
  if (f) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
