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