#include <bits/stdc++.h>
int main() {
  int a = 0, b = 0, count = 0;
  std::string code;
  std::cin >> a >> b >> code;
  for (int i = 0; i < code.length(); i++) {
    if (code[i] == '-') {
      count++;
    }
  }
  if (a + b + 1 != code.length() || code[a + 1] != '-' || count < 1 ||
      count > 1) {
    std::cout << "No" << std::endl;
  } else {
    std::cout << "Yes" << std::endl;
  }
}
