#include <bits/stdc++.h>
using namespace std;
const int Inf = 1e9;
const double EPS = 1e-9;
int gcd(int a, int b) {
  if (b == 0) {
    return a;
  } else {
    return gcd(b, a % b);
  }
}
int lcm(int a, int b) { return a * b / gcd(a, b); }
int bitCount(long bits) {
  bits = (bits & 0x55555555) + (bits >> 1 & 0x55555555);
  bits = (bits & 0x33333333) + (bits >> 2 & 0x33333333);
  bits = (bits & 0x0f0f0f0f) + (bits >> 4 & 0x0f0f0f0f);
  bits = (bits & 0x00ff00ff) + (bits >> 8 & 0x00ff00ff);
  return (bits & 0x0000ffff) + (bits >> 16 & 0x0000ffff);
}
int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  int a, b;
  cin >> a >> b;
  bool ans = true;
  string s;
  cin >> s;
  char c;
  for (int i = 0; i < (int)a; ++i) {
    c = s[i];
    if (!(c >= '0' && c <= '9')) ans = false;
  }
  c = s[a];
  if (c != '-') ans = false;
  for (int i = b; i < (int)s.size(); ++i) {
    c = s[i];
    if (!(c >= '0' && c <= '9')) ans = false;
  }
  if (ans) {
    cout << "Yes" << '\n';
  } else {
    cout << "No" << '\n';
  }
  return 0;
}
