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