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