#include <bits/stdc++.h>
using namespace std;
using vi = vector<int>;
using vb = vector<bool>;
using vc = vector<char>;
using vs = vector<string>;
using vvi = vector<vector<int>>;
using vvc = vector<vector<char>>;
using pii = pair<int, int>;
int main() {
  int a, b;
  string s;
  cin >> a >> b >> s;
  for (int i = 0; i < (int)(a); i++) {
    int tmp = s.at(i) - '0';
    if (0 <= tmp && tmp <= 9) continue;
    cout << "No" << endl;
    return 0;
  }
  if (s.at(a) != '-') {
    cout << "No" << endl;
    return 0;
  }
  for (int i = 0; i < (int)(b); i++) {
    int tmp = s.at(a + 1 + i);
    if (0 <= tmp && tmp <= 9) continue;
    cout << "No" << endl;
    return 0;
  }
  cout << "Yes" << endl;
}
