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