#include <bits/stdc++.h>
using namespace std;
int main() {
  int A, B;
  cin >> A >> B;
  string s1;
  cin >> s1;
  string ans = "Yes";
  for (int i = 0; i < A; i++) {
    if (s1.at(i) != '0' && s1.at(i) != '1' && s1.at(i) != '2' &&
        s1.at(i) != '3' && s1.at(i) != '4' && s1.at(i) != '5' &&
        s1.at(i) != '6' && s1.at(i) != '7' && s1.at(i) != '8' &&
        s1.at(i) != '9') {
      ans = "No";
      break;
    }
  }
  if (s1.at(A) != '-') {
    ans = "No";
  }
  for (int j = A + 1; j < B; j++) {
    if (s1.at(j) != '0' && s1.at(j) != '1' && s1.at(j) != '2' &&
        s1.at(j) != '3' && s1.at(j) != '4' && s1.at(j) != '5' &&
        s1.at(j) != '6' && s1.at(j) != '7' && s1.at(j) != '8' &&
        s1.at(j) != '9') {
      ans = "No";
      break;
    }
  }
  cout << ans << endl;
}
