#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main(void) {
  int A, B;
  string S;
  cin >> A >> B;
  cin >> S;
  if (S[A + 1] = "-" && S.size() == A + B + 1) {
    cout << "Yes";
  } else {
    cout << "No";
  }
}
