#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  int A, B;
  int ans = 0;
  cin >> s >> A >> B;
  for (int i = 0; i < A; ++i) {
    if (s[i] == '0' || s[i] == '1' || s[i] == '2' || s[i] == '3' ||
        s[i] == '4' || s[i] == '5' || s[i] == '6' || s[i] == '7' ||
        s[i] == '8' || s[i] == '9') {
      ;
    } else {
      ans = ans + 1;
    }
  }
  if (s[A] == '-') {
    ;
  } else {
    ans = ans + 1;
  }
  for (int i = A + 1; i < B + A + 1; ++i) {
    if (s[i] == '0' || s[i] == '1' || s[i] == '2' || s[i] == '3' ||
        s[i] == '4' || s[i] == '5' || s[i] == '6' || s[i] == '7' ||
        s[i] == '8' || s[i] == '9') {
      ;
    } else {
      ans = ans + 1;
    }
  }
  if (ans == 0) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
  return 0;
}
