#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  int a, b;
  int dum = 0;
  cin >> a >> b;
  cin >> s;
  for (int i = 0; i < s.size(); i++) {
    if (isdigit(s[i]))
      dum++;
    else {
      if (s[i] != '-' and i != a) {
        cout << "No";
        break;
      }
    }
  }
  if (dum == a + b)
    cout << "Yes";
  else
    cout << "No";
  return 0;
}
