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