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