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