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