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