#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  string s;
  cin >> a >> b >> s;
  for (int i = (0); i < (int)(a); i++) {
    if (s[i] == '-' || !isdigit(s[i])) {
      cout << "No" << endl;
      return 0;
    }
  }
  if (s[a] != '-') {
    cout << "No" << endl;
    return 0;
  }
  for (int i = (a + 1); i < (int)(a + b + 1 || !isdigit(s[i])); i++) {
    if (s[i + a + 1] == '-') {
      cout << "No" << endl;
      return 0;
    }
  }
  cout << "Yes" << endl;
  return 0;
}
