#include <bits/stdc++.h>
static inline bool is_number(char ch) { return ch <= '9' && ch >= '1'; }
int main(int argc, char **argv) {
  int a, b, count = 0;
  std::string str;
  std::cin >> a >> b;
  std::cin >> str;
  if ((unsigned int)(a + b + 1) != str.size()) {
    goto bad;
  }
  for (count = 0; count < a; ++count) {
    if (!is_number(str.at(count))) {
      goto bad;
    }
  }
  if (str.at(count++) != '-') {
    goto bad;
  }
  b += count;
  for (; count < b; ++count) {
    if (!is_number(str.at(count))) {
      goto bad;
    }
  }
  std::cout << "Yes" << std::endl;
  return 0;
bad:
  std::cout << "No" << std::endl;
  return 0;
}
