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