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