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