#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using vi = vector<int>;
const ll linf = 1LL << 62;
const int inf = 999999;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
ll gcd(ll a, ll b) {
  if (a % b == 0)
    return b;
  else
    gcd(b, a % b);
}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }
int main() {
  int a, b;
  string s;
  cin >> a >> b;
  cin >> s;
  bool jud = true;
  if (s.length() != a + b + 1)
    jud = false;
  else {
    for (int i = 0; i < s.length(); i++) {
      if (s[i] >= '0' && s[i] <= '9')
        jud = true;
      else
        jud = false;
    }
  }
  if (s[a] != '-') jud = false;
  if (jud)
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}
