#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  cin >> a >> b;
  string s;
  cin >> s;
  regex regex(R"(\d+)");
  if (regex_search(s.begin(), s.begin() + (a - 1), regex) &&
      *(s.begin() + a) == '-' &&
      regex_search(s.begin() + (a + 1), s.end(), regex)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
  return 0;
}
