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