#include <bits/stdc++.h>
using namespace std;
using ll = long long;
ll ts = 1000000007;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  bool can = true;
  ll a, b;
  string s;
  cin >> a >> b >> s;
  while (true) {
    for (ll i = 0; i < a; i++) {
      if ('0' <= s[i] && s[i] <= '9') {
        can = true;
      } else {
        can = false;
        break;
      }
    }
    if (!can) {
      break;
    }
    if (s[a] != '-') {
      can = false;
    }
    if (!can) {
      break;
    }
    for (ll i = a + 1; i < b; i++) {
      if ('0' <= s[i] && s[i] <= '9') {
        can = true;
      } else {
        can = false;
        break;
      }
    }
    break;
  }
  cout << (can ? "Yes" : "No") << "\n";
}
