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