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