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