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