#include <bits/stdc++.h>
using namespace std;
int main() {
  string a;
  int i, j, c = 0, l, m, n, f = 0;
  cin >> m >> n;
  cin >> a;
  if (a[m] == '-') f = 1;
  for (i = 0; i < m; i++) {
    if (a[i] == '-') f = 0;
  }
  for (i = m + 1; i < n; i++) {
    if (f == 1 && a[i] >= '0' && a[i] <= '9') c++;
  }
  if (f == 1 && c == n)
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}
