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