#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int A, B;
  string S;
  cin >> A >> B;
  cin >> S;
  if (S[A] != '-') {
    cout << "No\n";
    return 0;
  }
  for (int i = A + 1; i < S.length(); ++i) {
    if (!('0' <= S[i] && S[i] <= '9')) {
      cout << "No\n";
      return 0;
    }
  }
  cout << "Yes\n";
  return 0;
}
