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