#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int A, B;
  cin >> A >> B;
  string s;
  cin >> s;
  if (s[A] != '-')
    cout << "No" << endl;
  else {
    int ans = 0;
    for (int i = 0; i < A; i++) {
      if (s[i] == '-') ans++;
    }
    for (int i = B; i <= A + B; i++) {
      if (s[i] == '-') ans++;
    }
    if (ans == 0)
      cout << "Yes" << endl;
    else
      cout << "No" << endl;
  }
  return 0;
}
