#include <bits/stdc++.h>
using namespace std;
int n, a, b;
char s;
int main() {
  cin >> a >> b;
  for (int i = 0; i <= a + b; i++) {
    cin >> s;
    if (i != a) {
      if (s < 48 || s > 58) {
        cout << s << endl;
        cout << "No" << endl;
        return 0;
      }
    } else {
      if (s != 45) {
        cout << s << endl;
        cout << "No" << endl;
        return 0;
      }
    }
  }
  cout << "Yes" << endl;
  return 0;
}
