#include <bits/stdc++.h>
using namespace std;
int main() {
  int A, B;
  cin >> A >> B;
  string S;
  cin >> S;
  if (S.length() != A + B + 1) {
    cout << "No" << endl;
    return 0;
  }
  bool isVaild = true;
  for (int i = 0, l = S.length(); i < l; ++i) {
    if (i == A && S[i] == '-') continue;
    if (i != A && ('0' <= S[i] || S[i] <= '9')) continue;
    isVaild = false;
    break;
  }
  cout << (isVaild ? "Yes" : "No") << endl;
}
