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