#include <bits/stdc++.h>
using namespace std;
int main() {
  int A, B;
  string S;
  cin >> A >> B;
  cin >> S;
  int count = 0;
  for (auto& i : S) {
    if (count == A) {
      if (i != '-') {
        cout << "No";
        return 0;
      }
    }
    if (i != '-') {
      count++;
    } else {
      if (count != A) {
        cout << "No";
        return 0;
      }
    }
  }
  cout << "Yes";
  return 0;
}
