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