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