#include <bits/stdc++.h>
using namespace std;
int main() {
  long long A, B;
  cin >> A >> B;
  string s;
  cin >> s;
  if (s[A] == '-') {
    for (long long i = 0; i < A; i++) {
      if (s[i] >= '0' && s[i] <= '9') {
      } else {
        cout << "No" << endl;
        return 0;
      }
    }
    for (long long i = A + 1; i < B + 1; i++) {
      if (s[i] >= '0' && s[i] <= '9') {
      } else {
        cout << "No" << endl;
        return 0;
      }
    }
  } else {
    cout << "No" << endl;
    return 0;
  }
  cout << "Yes" << endl;
  return 0;
}
