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