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