#include <bits/stdc++.h>
using namespace std;
int main() {
  int A, B;
  string S;
  cin >> A >> B >> S;
  int ans = 1;
  for (int i = 0; i < A; i++) {
    if (S[i] < '0' || S[i] > '9') {
      ans = 1;
      break;
    }
  }
  if (ans) {
    if (S[A] != '-') ans = 0;
  }
  if (ans) {
    for (int i = A + 1; i < A + B + 1; i++) {
      if (S[i] < '0' || S[i] > '9') {
        ans = 0;
        break;
      }
    }
  }
  cout << (ans ? "Yes" : "No") << endl;
}
