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