#include <bits/stdc++.h>
using namespace std;
using P = pair<int, int>;
int main(void) {
  int a, b;
  cin >> a >> b;
  string s;
  cin >> s;
  int cnt = 0;
  for (int i = 1; i < s.length() - 1; i++) {
    if (s.at(i) == '-') {
      cnt++;
      if (cnt = 1) {
        cout << "Yes" << endl;
        return 0;
      }
    }
  }
  cout << "No" << endl;
  return 0;
}
