#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  bool pd = 0;
  string s;
  cin >> a >> b >> s;
  for (int i = 0; i < a; i++) {
    if (s[i] <= '0' || s[i] >= '9') {
      pd = 1;
      break;
    }
  }
  if (s[a] != '-') pd = 1;
  for (int i = a + 1; i < a + b + 1; i++) {
    if (s[i] <= '0' || s[i] >= '9') {
      pd = 1;
      break;
    }
  }
  if (pd)
    cout << "No";
  else
    cout << "Yes";
  cout << endl;
  return 0;
}
