#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  int a, b;
  cin >> a >> b;
  string s;
  cin >> s;
  int t = 0;
  for (int i = 0; i < s.size(); i++) {
    if (s.at(i) == '-') {
      t = i;
    }
  }
  if (t == a) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
