#include <bits/stdc++.h>
int main(int argc, char** argv) {
  int a, b;
  std::string str;
  std::cin >> a >> b;
  std::cin >> str;
  const char* str_p = str.c_str();
  for (int i = 0; i < str.length(); i++) {
    if (i < a && str_p[i] == '-') {
      std::cout << "No";
      return 0;
    }
    if (i == a + 1 && str_p[i] != '-') {
      std::cout << "No";
      return 0;
    }
    if (i > a + 1 && str_p[i] == '-') {
      std::cout << "No";
      return 0;
    }
  }
  std::cout << "Yes" << std::endl;
  return 0;
}
