#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  cin >> a >> b;
  string S;
  cin >> S;
  bool ok = true;
  for (int(i) = 0; (i) < (a); (i)++) {
    if (!(('0' <= S[i]) && (S[i] <= '9'))) {
      ok = false;
    }
  }
  if (!(S[a] == '-')) {
    ok = false;
  }
  for (int i = a + 1; i <= b; i++) {
    if (!(('0' <= S[i]) && (S[i] <= '9'))) {
      ok = false;
    }
  }
  if (ok)
    puts("Yes");
  else
    puts("No");
}
