#include <bits/stdc++.h>
bool check(char c) {
  for (int i = 0; i < 10; i++) {
    if (c == '0' + i) {
      return true;
    }
  }
  return false;
}
int main() {
  int A, B;
  std::string S;
  std::cin >> A >> B >> S;
  for (int i = 0; i < A; i++) {
    if (!check(S[i])) {
      std::cout << "No" << std::endl;
      return 1;
    }
  }
  if (S[A] != '-') {
    std::cout << "No" << std::endl;
    return 1;
  }
  for (int i = A + 1; i < S.size(); i++) {
    if (!check(S[i])) {
      std::cout << "No" << std::endl;
      return 1;
    }
  }
  std::cout << "Yes" << std::endl;
  return 0;
}
